You could use the isNaN Function. It returns true if the data is not a number. That would be something like that:
function checkInp()
{
var x=document.forms["myForm"]["age"].value;
if (isNaN(x)) // this is the code I need to change
{
alert("Must input numbers");
return false;
}
}
Note: isNan considers 10.2 as a valid number.