La ida es crear diversos menus de salto que con un solo boton de submit me pueda llevar al enlace correcto.
El problema que encuentro es que el boton submit obedece unicamente al un solo select, por lo que mi imagino que se requiere de un codigo php y javascript para crear este nuevo submit
gracias y buen dia
LES DEJO ALGO DEL COGIDO PARA VER QUE OPINAN
Código HTML:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Documento sin título</title> </head> <body> <script type="text/javascript"> function MM_resolveTargetUrl(firstObjId,secondObjId,tercer,targ,restore){ var firstSelObj = null; var secondSelObj = null; var tercer = null; with (document){ if (getElementById) { firstSelObj = getElementById(firstObjId); secondSelObj = getElementById(secondObjId); tercer = getElementById(tercerId); }// end if // WARNING: The following logic will only work if the initial values of the dropdown boxes are ---TEST1--- and ---TEST2--- // Change the if condition if the initial values are something else!! if (firstSelObj.value == "---TEST1---"){ // user has not selected from first dropdown if (secondSelObj.value == "---TEST2---") { // user has not selected from the second dropdown if (tercer.value == "---TEST3---") { // user has not selected from the second dropdown alert("Please select an option from the dropdown menus!"); return }// end nested if else { // user has selected from the second dropdown eval(targ+".location='"+secondSelObj.options[secondSelObj.selectedIndex].value+"'"); if (restore) firstSelObj.selectedIndex=0; if (restore) secondSelObj.selectedIndex=0; if (restore) tercer.selectedIndex=0; return; }// end nested else }// end if else { // user has selected from the first dropdown eval(targ+".location='"+firstSelObj.options[firstSelObj.selectedIndex].value+"'"); if (restore) firstSelObj.selectedIndex=0; if (restore) secondSelObj.selectedIndex=0; if (restore) tercer.selectedIndex=0; return; }// end else }// end with }// end MM_resolveTargetUrl eval(targ+".location='"+tercer.options[tercer.selectedIndex].value+"'"); if (restore) firstSelObj.selectedIndex=0; if (restore) secondSelObj.selectedIndex=0; if (restore) tercer.selectedIndex=0; return; }// end else }// end with }// end MM_resolveTargetUrl </script> </head> <body> <form name="form" id="form" accept-charset="" > <!-- WARNING: There is logic in the MM_resolveTargetUrl function above that relies on the initial values of the dropdown boxes. If the initial values ---TEST1--- and ---TEST2--- change, the if conditions in the function must be changed as well!! --> <select name="jumpMenu" id="jumpMenu" style="background-color:#fff; width:150px; color:#666;"> <option selected = "TEST1" class="red" style="font-size: 0.9em; font-family: Arial; text-indent:0.3em; ">---TEST1---</option> <option value="http://www.google.com" style="font-size: 0.9em; font-family: Arial;">GOOGLE</option> </select> <!-- WARNING: There is logic in the MM_resolveTargetUrl function above that relies on the initial values of the dropdown boxes. If the initial values ---TEST1--- and ---TEST2--- change, the if conditions in the function must be changed as well!! --> <select name="jumpMenu2" id="jumpMenu2" style="background-color:#000; width:150px; color:#CCC;"> <option selected = "TEST2" style="font-size: 0.9em; font-family: Arial;">---TEST2---</option> <option value="http://www.yahoo.com" style="font-size: 0.9em; font-family: Arial;">YAHOO</option> </select> <select name="jumpMenu3" id="jumpMenu3" style="background-color:#000; width:150px; color:#CCC;"> <option selected = "TEST3" style="font-size: 0.9em; font-family: Arial;">---TEST2---</option> <option value="http://www.yahoo.com" style="font-size: 0.9em; font-family: Arial;">YAHOO</option> </select> <input type="button" name="go_button" id= "go_button" value="Go" onClick="MM_resolveTargetUrl('jumpMenu','jumpMenu2','jumpMenu3','parent',1)" > </legend> </form> </body> </html>
ESTE ES EL CODIGO QUE YO ESTABA EDITANDO, PERO AQUI LES DEJO EL ORIGINAL...
Código HTML:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Documento sin título</title> </head> <body> <script type="text/javascript"> function MM_resolveTargetUrl(firstObjId,secondObjId,targ,restore){ var firstSelObj = null; var secondSelObj = null; with (document){ if (getElementById) { firstSelObj = getElementById(firstObjId); secondSelObj = getElementById(secondObjId); }// end if // WARNING: The following logic will only work if the initial values of the dropdown boxes are ---TEST1--- and ---TEST2--- // Change the if condition if the initial values are something else!! if (firstSelObj.value == "---TEST1---"){ // user has not selected from first dropdown if (secondSelObj.value == "---TEST2---") { // user has not selected from the second dropdown alert("Please select an option from the dropdown menus!"); return }// end nested if else { // user has selected from the second dropdown eval(targ+".location='"+secondSelObj.options[secondSelObj.selectedIndex].value+"'"); if (restore) firstSelObj.selectedIndex=0; if (restore) secondSelObj.selectedIndex=0; return; }// end nested else }// end if else { // user has selected from the first dropdown eval(targ+".location='"+firstSelObj.options[firstSelObj.selectedIndex].value+"'"); if (restore) firstSelObj.selectedIndex=0; if (restore) secondSelObj.selectedIndex=0; return; }// end else }// end with }// end MM_resolveTargetUrl </script> </head> <body> <form name="form" id="form" accept-charset="" > <!-- WARNING: There is logic in the MM_resolveTargetUrl function above that relies on the initial values of the dropdown boxes. If the initial values ---TEST1--- and ---TEST2--- change, the if conditions in the function must be changed as well!! --> <select name="jumpMenu" id="jumpMenu" style="background-color:#fff; width:150px; color:#666;"> <option selected = "TEST1" class="red" style="font-size: 0.9em; font-family: Arial; text-indent:0.3em; ">---TEST1---</option> <option value="http://www.google.com" style="font-size: 0.9em; font-family: Arial;">GOOGLE</option> </select> <!-- WARNING: There is logic in the MM_resolveTargetUrl function above that relies on the initial values of the dropdown boxes. If the initial values ---TEST1--- and ---TEST2--- change, the if conditions in the function must be changed as well!! --> <select name="jumpMenu2" id="jumpMenu2" style="background-color:#000; width:150px; color:#CCC;"> <option selected = "TEST2" style="font-size: 0.9em; font-family: Arial;">---TEST2---</option> <option value="http://www.yahoo.com" style="font-size: 0.9em; font-family: Arial;">YAHOO</option> </select> <input type="button" name="go_button" id= "go_button" value="Go" onClick="MM_resolveTargetUrl('jumpMenu','jumpMenu2','parent',1)" > </legend> </form> </body> </html>
SI SE DAN CUENTA EN EL ORIGINAL SI SE PUEDE, PERO EN EL QUE YO EDITO PARA AGREGAR MAS MENUS DE SALTO, ME TRABE DE TAL FORMA QUE YA ACABE CON JAQUECA........UN SALUDO Y OJALA PUEDAN AYUDARME