Ver Mensaje Individual
  #2 (permalink)  
Antiguo 04/01/2011, 12:54
kbmaster
 
Fecha de Ingreso: julio-2009
Mensajes: 42
Antigüedad: 14 años, 9 meses
Puntos: 3
Respuesta: como verifico que no tenga espacio en blanco?

Te paso 2 ideas :

//devuelve true si el texto tiene espacios
function tieneEspacios(texto)
{
return texto.match(/\s/);
}

//devuelve el texto sin los espacios
function Trim(texto)
{
return texto..replace(/\s/g,"");
}