I need to find out the previous year date from current date and then set as minDate in jQuery UIdatepicker in javascript
My date formaqt is dd-mm-yy
dd-mm-yy
Datepicker allows you to put a number as the minDate option, and it uses that as an offset from the current date. So you can write:
minDate
minDate: -365
to specify 1 year ago. This doesn't take leap years into account, though.