Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 1 of 1
09-03-2011, 02:14 PM #1
- Join Date
- Sep 2011
- Thanked 0 Times in 0 Posts
search result display page modification
HI, I am new to this php coding forum. i have a bit of code that i want help with.
I am attaching the searchtemplate.php file here. I have to do change so that when the search results are displayed, if the user has not found what he was searching for, he must be greeted with a message in html. Suppose i was searching for "mango" if i dont get mango, i will be told at search results display page to redefine search(as usually it is). What i want is to display a message too when user searches through a search box ( the code of which I am writng here). I have been asked to modify results function in searchtemplate.php . I have not figured it out yet.
I am complete novice in php. NAy guidance or help is appreciated. If anybody can just help me out where should i make a modification.
code of the search box that user searches through
echo '<form action="', $scripturl, '?action=search2" method="post" accept-charset="', $context['character_set'], '">
<input type="text" name="search" value="" class="sp_search" /><br /><br />
<input type="submit" name="submit" value="Search" />
<input type="hidden" name="advanced" value="0" />
<input type="hidden" name="brd" value="2" />';
for the code..
it is a php block of code that i use to display a search box to the users to search through a particular board. brd and the value="2" are for the respective board. (board is just same as sub forum in your forum)
i have attached the searchtemplate too.
It is in .txt format