Datepicker custom date range

Datepicker custom date range


I had a custom range function from the old examples.
function customRange(input) {
     return{minDate: (input.id == "archiveDate" ? $
("#newsDate").datepicker("getDate") : null),
     maxDate: (input.id == "newsDate" ? $
("#archiveDate").datepicker("getDate") : null)};
    }
    $("#newsDate, #archiveDate").datepicker({dateFormat: "M d, yy",
firstDay: 1, beforeShow: customRange, showOn: "button", buttonImage:
basedir+"css/"+cssStyle+"/images/te_news/form/calendar.png",
buttonImageOnly: true, showButtonPanel: true});
This code doesn't seems to work anymore with 1.7.
any help?
thanx