I have several Gallery installations and a forum. Each one has a search.php that takes a searchstring=blah variable (i.e. http://coleclan.net/videos/search?searchstring=blah )
I am trying to make a page that has a form where you enter a search string, select the Gallery or Forum that you want to search in, then click submit.
In my current attempt, since i know no other way to handle it, i am passing the collected data to a php file to handle redirection. ( search.processor.php ).
all that file has to do is redirect to the correct search.php adding the '?searchstring=blah' to the end.
it is not doing what i wanted it to...
here is my code...
groupsearch.php
<FORM METHOD=GET ACTION="search.processor.php">
Look for:
<INPUT NAME="searchstring"><BR>
In:
<input type="radio" name="section" value="http://forum.coleclan.net/search.php">Forums<br>
<input type="radio" name="section" value="http://games.coleclan.net/flash/search.php">Flash Games<br>
<input type="radio" name="section" value="http://games.coleclan.net/gallery/search.php">Game Screenshots Gallery<br>
<input type="radio" name="section" value="http://coleclan.net/photos/search.php">Photo Gallery<br>
<input type="radio" name="section" value="http://coleclan.net/videos/search.php">Videos<br>
<input type="radio" name="section" value="http://coleclan.net/wallpaper/search.php">Wallpaper<br>
<INPUT TYPE=SUBMIT value="Search">
</FORM>
and here is the 'search.processor.php'
<?php
while(list($section, $searchstring) = each($HTTP_GET_VARS))
echo "<SCRIPT LANGUAGE=\"JavaScript\">";
echo "<!--";
echo " function redirect()";
echo " { ";
echo " window.location = \"$section?$searchstring\"";
echo " }";
echo " setTimeout(\"redirect();\", 1)";
echo "//-->";
echo "</SCRIPT>";
?>
Ideas?
I hope i was clear enough with what i was trying to do here.. simpily put, there are lots of pre-fab search pages all over my site, i want to consolidate them.
Beavis2084