I´m trying to call two functions when closing the jQuery UI Datepicker, but I´m not sure what´s the best way to do this.
If I only have one function I can do this:
function splitArrivalDate() {
// Some code
}
$( '#mydatepicker' ).datepicker({
onClose: splitArrivalDate
});
But what if I want to call two functions sequentially on the onClose event?
function splitArrivalDate() {
// Some code
}
function setDepartureDate() {
// Some code
}
$( '#mydatepicker' ).datepicker({
onClose: splitArrivalDate; setDepartureDate // Does not work
});
I hope someone can help me understand this. Thanks!
You want something like this: