Ver Mensaje Individual
  #4 (permalink)  
Antiguo 17/06/2003, 01:49
Avatar de JavierB
JavierB
Colaborador
 
Fecha de Ingreso: febrero-2002
Ubicación: Madrid
Mensajes: 25.052
Antigüedad: 22 años, 4 meses
Puntos: 772
Hola, juandedios.

Creo que esto te servirá:
Código PHP:
<html>

<
head>
<
script>
function 
letra(e) {
    
tecla=(document.all) ? e.keyCode :e.which;
    if (
tecla!=65 && tecla!=97) return false;
}
</script>
</head>

<body>
<input type="text" onKeyPress="return letra(event)">
</body>

</html> 
He usado los valores 65 y 90 para la a mayúscula y minúscula. Cambialos según tus necesidades.

Saludos,