News:

Wondering if this will always be free?  See why free is better.

Main Menu

Search Focus Dropdown

Started by Brettflan, February 14, 2009, 02:34:48 PM

Previous topic - Next topic

TheListener

Quote from: hcfwesker on January 24, 2011, 07:06:43 PM
QuoteSince the error reporting seems completely off base, you might want to go into your Admin panel and go to Configuration->Features and Options->General. Make sure the option "Disable evaluation of templates" is unchecked. Only check that option once you've fully tested your themes and know that they work flawlessly.

I don't have that option at all in my AdminCP.  I'm on SMF2 RC4

For RC4 look in your server settings

hcfwesker

Yup, it's there.  I thought I checked there before.

But, it is 'unchecked' already by default.

Like you said, it may be caused from something other than this MOD.

NanoSector

This should really be a default part of SMF & it's custom themes :)
My Mods / Mod Builder - A tool to easily create mods / Blog
"I've heard from a reliable source that the Answer is 42. But, still no word on what the question is."

steve51184

hi just wanted to know how do i add a search option to the search dropdown box for a set category?

so if i have a board 'help' with id 12 the dropdown will show 'help' as the first option but with the other options also there

thanks

Brettflan

That would take a fair bit of modification on your part. Sounds like a decent idea for a new feature for me to add, though; more options in the admin panel to add specific boards to the dropdown like that.

I'll probably do that in the next week or two when I have time for it.

smartmouse

Hello, i have installed this great mod, but i have encountered a very little problem. Please have a look at this screenshot:



The two box are not aligned for 1 pixel!

Here is the related code in index.template.php file of my custom theme:

';

loadLanguage('SearchFocus');

// Viewing a topic?
if (!empty($context['current_topic']))
{
echo '
<input type="hidden" name="brd[', $context['current_board'], ']" value="', $context['current_board'], '" />';
$focus_options = '
<option value="topic" selected="selected">' . $txt['search_focus_topic'] . '</option>
<option value="board">' . $txt['search_focus_board'] . '</option>
<option value="all">' . $txt['search_focus_all'] . '</option>';
}
// Viewing a board?
elseif (!empty($context['current_board']))
$focus_options = '
<option value="board" selected="selected">' . $txt['search_focus_board'] . '</option>
<option value="all">' . $txt['search_focus_all'] . '</option>';
// Viewing something else, such as index
else
$focus_options = '
<option value="all" selected="selected">' . $txt['search_focus_all'] . '</option>';

// Google option enabled?
if (!empty($modSettings['search_focus_enable_google']))
$focus_options .= '
<option value="google">' . $txt['search_focus_google'] . '</option>';

// Show the search focus dropdown
echo '
<select name="search_focus" id="search_focus">' . $focus_options . '
</select>';

echo '
<input type="submit" name="submit" value="', $txt['search'], '" class="button_submit" />
<input type="hidden" name="advanced" value="0" />';


How to fix it?

Thank you.


Brettflan

Try adding this to your theme's index.css file:
select#search_focus
{
position: relative;
top: -1px;
}

smartmouse

It worked.

Just to understand... why i need this modify to fix it?

Thank you for your support ;)

Brettflan

For whatever reason, that's the way the controls line up by default.

smartmouse

Okay, thank you for your help.
Keep up the good work ;)

dougiefresh

#210
Thank you for the wonderful mod!  I thought I'd let everybody know that when I updated my forum from 2.0 RC5 to 2.0 Gold, I had to reinstall all my mods.  This mod installed without issues and using 2.0 RC5 emulation.  Hope this info helps someone!

Brettflan

I'll be checking over and updating this package in the next few days.

Brettflan

Released version 1.52:

  • support for installation on SMF 2.0 Final

I still haven't gotten around to adding in the capability to add specific boards to the dropdown, but it is still (eventually) planned. I've just been very busy with other concerns lately.

TheListener

Hey Brett

I have only installed this on my test forum so far and like the way it looks.

Regarding the board dropdown would it show all the boards or be permission specific?


Brettflan

The idea would be to add a list of all forum boards in the Admin panel, probably as a list of checkboxes. The admins could set which boards they want to show up in the dropdown on every page.

So, for example you could add your Support board or FAQ board (or whatever) to the dropdown, so people could quickly run a search on that specific board from anywhere in the forum.

TheListener

Sounds good.

Am willing to be a guinea pig for ya.

:-X ( Well it is 5:16am )

cubby61

Instead of Google can you add a option to search either Google or Bing (Admins's choice in the settings)?

Brettflan

At the moment I don't have time to work on further features for this mod package at all, but I'll consider it when I do have time.

gisfreak

hello, nice mod

but I have a problem when install this on my forum, all look messy

see the screenshoot

I use Ant's prince of darkness themes
Me fail English? That's unpossible.

Brettflan

I actually haven't tested his new versions, so it looks like I need to do so.

Advertisement: