Archive for howtodoit.myfastforum.org 
 



       howtodoit.myfastforum.org Forum Index -> Add-on`s for your forum
Symon

search bar

To add a search bar which mimics the standard search form with hidden fields set to search for all terms and show topics from all forums as the values to be passed.





to your overall_header.tpl

Code:
 <form action="search.php?mode=results" method="POST">
<input type="text" style="width: 300px" class="post" name="search_keywords" size="30" /><input type="hidden" name="search_terms" value="all" ><input type="hidden" name="search_forum" value="-1"><input type ="hidden" name="search_time" value="9999"><input type="hidden" name="search_fields" value="all" /> <input type="hidden" name="search_cat" value="-1"><input type="hidden" name="sort_by" value="0"/><input type="hidden" name="sort_dir" value="DESC" /><input type="hidden" name="show_results" value="topics" /><input type="hidden" name="return_chars" value="-1"/><input class="liteoption" type="submit" value="Search" /></form>


to make the button appear in a normal post the code changes a slight bit and becomes (remember to add form,input to admin panel --general admin -- configuation --allow html tags


Code:
<form action="search.php?mode=results" method="POST">
<input type="width: 300px" class="post" name="search_keywords" size="30" /><input type="hidden" name="search_terms" value="all" ><input type="hidden" name="search_forum" value="-1"><input type ="hidden" name="search_time" value="9999"><input type="hidden" name="search_fields" value="all" /> <input type="hidden" name="search_cat" value="-1"><input type="hidden" name="sort_by" value="0"/><input type="hidden" name="sort_dir" value="DESC" /><input type="hidden" name="show_results" value="topics" /><input type="hidden" name="return_chars" value="-1"/><input class="liteoption" type="submit" value="Search" /></form>

       howtodoit.myfastforum.org Forum Index -> Add-on`s for your forum
Page 1 of 1
Create your own free forum | Buy a domain to use with your forum