javascript - jQuery Date format invalid -


why shows different date 05/05/1972 instead of 29/05/1970?

$(document).ready(function(){     alert($.datepicker.formatdate('dd/mm/yy', new date("29/05/1970"))); }); 

jsfiddle

try this...

$(document).ready(function(){    alert($.datepicker.formatdate('dd/mm/yy', new date(1970, 5, 29)));  });


Comments

Popular posts from this blog

java - Unable to make sub reports with Jasper -

sql - The object name contains more than the maximum number of prefixes. The maximum is 2 -

scala - play framework: Modules were resolved with conflicting cross-version suffixes -