Knowledge Base

Remove search box & add search icon in navbar
Article ID: 715
Written By: Mick
Written On: Fri Jun 12, 2009 9:46 am
Description: For whatever reason you may want to get rid of the search box in the header and or add a search icon to the navbar. You can do either with this.
link to this article on phpbb.com: Select All
[kb=remove-search-box+add-search-icon-in-navbar]Remove search box & add search icon in navbar[/kb]
link to this article on your own board: Select All
[url=http://www.phpbb.com/kb/article/remove-search-box+add-search-icon-in-navbar/]Knowledge Base - Remove search box & add search icon in navbar[/url]

Remove Search Box

Open styles/prosilver/template/overall_header.html

Find and remove:
Code: Select all
<!-- IF S_DISPLAY_SEARCH and not S_IN_SEARCH -->
             <div id="search-box">
                <form action="{U_SEARCH}" method="post" id="search">
                <fieldset>
                   <input name="keywords" id="keywords" type="text" maxlength="128" title="{L_SEARCH_KEYWORDS}" class="inputbox search" value="<!-- IF SEARCH_WORDS-->{SEARCH_WORDS}<!-- ELSE -->{L_SEARCH_MINI}<!-- ENDIF -->" onclick="if(this.value=='{LA_SEARCH_MINI}')this.value='';" onblur="if(this.value=='')this.value='{LA_SEARCH_MINI}';" />
                   <input class="button2" value="{L_SEARCH}" type="submit" /><br />
                   <a href="{U_SEARCH}" title="{L_SEARCH_ADV_EXPLAIN}">{L_SEARCH_ADV}</a> {S_SEARCH_HIDDEN_FIELDS}
                </fieldset>
                </form>
             </div>
          <!-- ENDIF --> 

Refresh your template.
ACP:: Styles Tab > Templates > Prosilver > Refresh

Add search icon to navbar

Open styles/prosilver/template/overall_header.html.

Find:
Code: Select all
<li class="icon-faq"><a href="{U_FAQ}" title="{L_FAQ_EXPLAIN}">{L_FAQ}</a></li> 

Before, add:
Code: Select all
<!-- IF S_DISPLAY_SEARCH --><li class="icon-search"><a href="{U_SEARCH}" title="{L_SEARCH_ADV_EXPLAIN}">{L_SEARCH}</a></li><!-- ENDIF -->


Refresh your template.
ACP:: Styles Tab > Templates > Prosilver > Refresh