Validate date format mm/dd/yyyy by using jquery validation library
First add the custom method to the validation library as below. Can you put this code in your jquery validation file or in your page where you want to validate…
First add the custom method to the validation library as below. Can you put this code in your jquery validation file or in your page where you want to validate…
<script type="text/javascript"> function isValideDate(datavalue){ var regexValidDate = /^(?:(0|1)(0||3)(19|20){2})$/; return regexValidDate.test(datavalue); } var dateToCheck = '06/01/2011', if(isValideDate(dateToCheck)){ alert("Given date is valid as per the format of MM/dd/YYYY"); }else{ alert("Given date is…
<html> <body> <h1>Welcome to my Website</h1> <h4 id=”msg”>You will be redirected to another page in 5 seconds!</h4> <script type=”text/javascript”> function countDown(i, callback) { callback = callback || function(){}; var int…
How to validate and restrict unwanted character for name field using jquery $(document).ready(function () { $(‘#name’).keyup(function () { var $th = $(this); $th.val($th.val().replace(//g, function (str) { return ”; })); });…