Click to See Complete Forum and Search --> : help with a site search


soapmyster
09-30-2004, 12:35 AM
I am trying to figure out how to get this script to work...
its a site search with catogories or fields..so I am trying to get it to search my sites by different catogories..CAN anyone help me with this.


<html>

<head>

<title>Dynamic Form Action</title>

<script language="JavaScript">

<!--



function getAction() {

formAction = document.myForm.myMenu[document.myForm.myMenu.selectedIndex].value

document.myForm.action = formAction

}



// -->

</script>



</head>



<body>

<form name="myForm" method="get" action="" onSubmit="getAction();">





<p align="center"><b>Catogories</b><select name="myMenu">

<option selected="selected" value="All">[ All ]</option>

<option value="http://www.name.com/ROM/index.html">CD/DVD-ROM</option>

<option value="http://www.name.com/RW/index.html">CD/DVD-RW</option>

<option value="http://www.name.com/CPU/index.html">CPU</option>

<option value="http://www.name.com/Cases/index.html">Cases</option>

<option value="http://www.name.com/HHD/index.html">Hard Drive</option>

<option value="http://www.name.com/Media/index.html">Media</option>

<option value="http://www.name.com/Memory/index.html">Memory</option>

<option value="http://www.name.com/Monitors/index.html">Monitors</option>

<option value="http://www.name.com/Motherboard/index.html">Motherboard</option>

<option value="http://www.name.com/Mouse_Keyboard/index.html">Mouse/Keyboard</option>

<option value="http://www.name.com/Networking/index.html">Networking</option>

<option value="http://www.name.com/Power_Supplies/index.html">Power Supplies</option>

<option value="http://www.name.com/Printers/index.html">Printers</option>

<option value="http://www.name.com/Sound/index.html">Sound Card</option>

<option value="http://www.name.com/Video/index.html">Video Card</option>

<option value="http://www.name.com/Accessories/index.html">Accessories</option>

</select>



<b>Search For</b><input type="text" name="searchField" size="29">



<input type="submit" name="submit" value="Search">



</p>



</form>