Can anyone tell me what the two lines do here?
( charCode < 48 || charCode > 57))
I guess it means something like "or" or "do both"...
function numberCheck(evt)
{
var charCode = (evt.which) ? evt.which : event.keyCode;
if (charCode > 31 && ( charCode < 48 || charCode > 57))
{
document.getElementById("numonly").innerHTML = "Numbers Please!";
return false;
}
else
{
document.getElementById("numonly").innerHTML = "";
return true;
}
}
So what your saying is that the code is looking for all characters except 48-57?