E` gia` stato affrontato piu` volte.

Ad esempio:
if(document.NOMEFORM.NOMECAMPO.value.match(/^\d*$/) ) alert("il campo contiene un numero intero")