Ah, now that I look at your code again, you've got .datepicker(options)
in one place, that looks right. Below you have .datepick("getDate") That should be .datepicker("getDate") - Richard On Thu, Jan 15, 2009 at 4:24 AM, divsystem <divsys...@gmail.com> wrote: > > $('.Datepicker1').datepicker({beforeShow: customRange, > rangeSelect: true, numberOfMonths: 2}); > > function customRange(input) { > return { > minDate: (input.id == "startDatepicker" ? $ > ("#endDatepicker").datepick("getDate") : null), > maxDate: (input.id == "endDatepicker" ? $ > ("#startDatepicker").datepick("getDate") : null) > }; > } > > > > <p>startDate: <input type="text" id="startDatepicker" class = > "Datepicker1"></p> > <p>endDate: <input type="text" id="endDatepicker" class = > "Datepicker1"></p> >