Ver Mensaje Individual
  #2 (permalink)  
Antiguo 29/05/2006, 01:51
Avatar de JavierB
JavierB
Colaborador
 
Fecha de Ingreso: febrero-2002
Ubicación: Madrid
Mensajes: 25.052
Antigüedad: 22 años, 2 meses
Puntos: 772
Hola josodi

A ver si te sirve esto:
Código PHP:
<html>
<
head>
<
script type="text/javascript">
function 
validar(texto) {
  
patron = /[-_.]/;
  return !(
patron.test(texto) || texto.length<|| texto.length>20)
}
</script>
</head>
<body>
<form action="algo.php" onsubmit="return validar(txt.value)">
<textarea name="txt"></textarea>
<input type="submit" />
</form>
</body>
</html> 
Saludos,