Allow only numbers in textbox jquery

  • For allowing only numbers in textbox using jQuery, you can create key-press or key-down or key-up event for textbox by using textbox id or class.
  • In below example i used class name ("number") for applying validation to textbox. 
  • You just had copy above code and paste where you want to apply numeric validation.

For allowing numbers with decimal points 

Comments

Popular posts from this blog

Display image from byte array in ASP.NET MVC

Convert a color image to black and white image in C#

Export excel and Pdf with Kendo UI MVC c#