This javascript will help you to validate the textbox in a form. This java script function helps you to check whether the given value in the textbox is number or integer value.
<body> tag
<form name=test> <input type=text name=en onKeyup="isInteger(this.value)"> <input type=button name=cc value="Check"> </form>
<head> tagof your page.