Click to See Complete Forum and Search --> : Drop down menu problem
sockcymbal
12-26-2002, 11:09 AM
I have made a drop down menu using the genorator and it works great. The only problem is, It won't let me have 2...If I paste 2 or more into the body, they all show up, but they do not function. Does anyone know how I can make more than 1 working drop down menu on a page? By the way, I did make these on separate layers too...
Maybe you could post your code. I'm guessing that they use the same functions...
sockcymbal
12-26-2002, 12:24 PM
the code is:
<form name="jump">
<select name="menu">
<option value="#">Navigation</option>
<option value="file://Macintosh/Users/nathan/Desktop/sockcymbal/website/main.dwt">News</option>
<option value="file://Macintosh/Users/nathan/Desktop/sockcymbal/website/shows.dwt">Shows</option>
<option value="file://Macintosh/Users/nathan/Desktop/sockcymbal/website/reviews.dwt">Reviews</option>
<option value="file://Macintosh/Users/nathan/Desktop/sockcymbal/website/bands.dwt">Bands</option>
<option value="file://Macintosh/Users/nathan/Desktop/sockcymbal/website/aboutus.dwt">About us</option>
<option value="file://Macintosh/Users/nathan/Desktop/sockcymbal/website/contact.dwt">Contact</option>
</select>
<input name="button" type="button" onClick="location=document.jump.menu.options[document.jump.menu.selectedIndex].value;" value="GO">
</form>
I have that same code on there twice, but with different links and stuff. Thanks
Ok, what you need to do is rename one of your forms. Name the first one like this...
<form name="jump">
and the second one like this...
<form name="jump2">
Then, for you second one, use this code for you GO button.
<input name="button" type="button" onClick="location=document.jump2.menu.options[document.jump2.menu.selectedIndex].value;" value="GO">
You had two forms with the same name, thus confusing the script.