jquery - Can not initialize Datepicker -


i have following snippets of code:

in js file:

$.datepicker.setdefaults({         dateformat: 'dd.mm.yy'     });  $("#performdateview").datepicker({   mindate: "0",   maxdate: "+3d",  });  var mydate = new date(1978,2,11)   $('#performdateview').datepicker( "setdate", mydate); 

and in html file:

<input type="text" id="performdateview" /> 

problem: maxdate , mindate worked, setdate property not. use jquery 1.9.1 should solve problem? have link: http://jsfiddle.net/rzd5z/

two things:

  • the input type should text. can either have browser's own datepicker or jquery ui's datepicker, not both.
  • you've set datepicker's minimum date today , maximum date 3 days today. march 1978 doesn't fit range date isn't set.

demo: http://jsfiddle.net/rzd5z/2/


Comments

Popular posts from this blog

image - ClassNotFoundException when add a prebuilt apk into system.img in android -

I need to import mysql 5.1 to 5.5? -

Java, Hibernate, MySQL - store UTC date-time -