Ver Mensaje Individual
  #2 (permalink)  
Antiguo 05/07/2004, 22:45
Avatar de TurKa
TurKa
 
Fecha de Ingreso: enero-2003
Ubicación: Gerli, Avellaneda
Mensajes: 543
Antigüedad: 22 años
Puntos: 4
Saludos mickeyy

Prueba con estos cambios:
Código:
<script language="JavaScript"> 
txt = "";
function cambia(){ 
funcion = frm.selector.options[frm.selector.selectedIndex].value; 
	if (funcion == "2") {
	txt = "1.-<input type=\"text\" name=\"uno\"><br>";
	txt += "2.-<input type=\"text\" name=\"dos\"><br>";
	}
	if (funcion == "3") {
	txt = "1.-<input type=\"text\" name=\"uno\"><br>";
	txt +="2.-<input type=\"text\" name=\"dos\"><br>";
	txt +=" 3.- <input type=\"text\" name=\"tres\"><br>";
	}
	if (funcion == "4") {
	txt = "1.-<input type=\"text\" name=\"uno\"><br>";
	txt +="2.-<input type=\"text\" name=\"dos\"><br>";
	txt +=" 3.- <input type=\"text\" name=\"tres\"><br>";
	txt+=" 4.- <input type=\"text\" name=\"cuatro\"><br>";
	}
document.write(txt);
}
</script> 
</head> 
<body> 
<form name="frm"> 
Seleccione el numero de respuestas:<select name="selector" onchange="cambia()"> 
<option>Seleccione un valor</option> 
<option value="2">Dos</option> 
<option value="3">Tres</option> 
<option value="4">Cuatro</option>
</select><br>
</form>
__________________
Programación LAMP con Scrum y XP
www.eugeniabahit.com.com.ar