jqueryexample.com jQuery .isNumeric() function - jqueryexample.com

jQuery .isNumeric() function by jqueryexample

jQuery .isNumeric() is new in jQuery 1.7. The $.isNumeric() method checks whether its argument represents a numeric value. If so, it returns true. and if input is not numeric then returns false. It is also useful as it also validate for decimal hex numbers and exponential strings.

$.isNumeric(16); // true

$.isNumeric(+10); // true

$.isNumeric(3.1415); // true

$.isNumeric(“8e5”); // true

$.isNumeric(NaN); // false

<script type="text/javascript">
isNumeric: function( obj ) {
return obj != null && rdigit.test( obj ) && !isNaN( obj );

Did you like this? Share it:


  1. Awesome things here. I’m very happy to see your article. Thank you so much and I’m having a look forward to touch you. Will you kindly drop me a mail?

Leave a Comment