How to set an input box that will only accept numeric values?
Jump to Post
Use clients side and server side techniques.
First, you can use HTML5 input type number to restrict only number entries:
<input type="number" name="txtBox1" />
This will work only in browsers that support this HTML5 input type.
function isNumber(e) …
All 6 Replies
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.