clarkj03
08-22-2008, 09:23 PM
I found this simple DD code, that allows a user to select an option and not need a submit button. I have 6 DD menus, but only the first is working. I have separated all functions into separate external .js files, and have a call to all of them in the head of my page. You can view the source code here http://www.kidsfirstweecycling.com ,it is the splash page.
Since I have 6 dd menus, I created 6 individual .js files. They all read the same with only the "city name" being changed throughout. In the example below the city name is "corona"... in the other 5 files it is changed to the other city names.
function coronanav()
{
var w = document.coronaform.coronalist.selectedIndex;
var url_add = document.coronaform.coronalist.options[w].value;
window.location.href = url_add;
}
I think it must be something simple, but since I am not fluent, I must be missing it.
Thanks!
Since I have 6 dd menus, I created 6 individual .js files. They all read the same with only the "city name" being changed throughout. In the example below the city name is "corona"... in the other 5 files it is changed to the other city names.
function coronanav()
{
var w = document.coronaform.coronalist.selectedIndex;
var url_add = document.coronaform.coronalist.options[w].value;
window.location.href = url_add;
}
I think it must be something simple, but since I am not fluent, I must be missing it.
Thanks!