Ver Mensaje Individual
  #3 (permalink)  
Antiguo 15/04/2011, 18:48
kryzpo23
 
Fecha de Ingreso: julio-2010
Ubicación: Chillan, Chile
Mensajes: 60
Antigüedad: 13 años, 9 meses
Puntos: 1
De acuerdo Respuesta: Habilitar desabilitar campos de texto con radioboton

Cita:
Iniciado por Manuellama Ver Mensaje
<!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>Text</title>
<script language="javascript">

function habilitar(){
* if(
document.getElementById("opcion1").checked ==true){
* document.getElementById("palabra1").disabled= false; * * * * *
* * }
* *
}
</script>
</head>

<body>
<form id="form1" method="post" action="#">
<input type="text" value="Inhabilitado" id="palabra1" disabled="enabled" />
<input name="radio" type="radio" id="opcion1" value="opcion1" onclick="habilitar()" />
</form>
</body>
</html>


Prueba eso.

Oh viejo muchas gracias, era precisamente lo que quería hacer, de hecho lo estoy aplicando con mas campos de texto y funciona.
Sin abusar de tu confianza me podrías recomendar algún tutorial que muestre que hacen casa una de estas funciones, ya que por lo que veo las utilizare frecuentemente.