Diferència entre revisions de la pàgina «Solució valor quadre text»
De wikiserver
(Es crea la pàgina amb «valor = document.getElementById("campo").value; if( valor == null || valor.length == 0 || /^\s+$/.test(valor) ) { return false; }».) |
|||
| Línia 1: | Línia 1: | ||
| + | <source type="java"> | ||
valor = document.getElementById("campo").value; | valor = document.getElementById("campo").value; | ||
if( valor == null || valor.length == 0 || /^\s+$/.test(valor) ) { | if( valor == null || valor.length == 0 || /^\s+$/.test(valor) ) { | ||
return false; | return false; | ||
} | } | ||
| + | |||
| + | </source> | ||
Revisió de 14:43, 18 gen 2015
valor = document.getElementById("campo").value;
if( valor == null || valor.length == 0 || /^\s+$/.test(valor) ) {
return false;
}