I can\'t get onSelect
working on my jQuery datepicker
.
Heres my code:
The best solution is to set the datepicker defaults
folows the code that I used
$.datepicker.setDefaults({
onSelect: function () {
$(this).focus();
$(this).nextAll('input, button, textarea, a').filter(':first').focus();
}
});
datePicker's onSelect equivalent is the dateSelected event.
$(function() {
$('.date-pick').datePicker( {
selectWeek: true,
inline: true,
startDate: '01/01/2000',
firstDay: 1,
}).bind('dateSelected', function(e, selectedDate, $td) {
alert(selectedDate);
});
});
This page has a good example showing the dateSelected event and other events being bound.