Created
July 21, 2016 22:15
-
-
Save jsteinshouer/dada251a5166c5240018ad96945e26ae to your computer and use it in GitHub Desktop.
Override Today button in Jquery UI Datepicker
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$.datepicker._gotoToday = function(id) { | |
var target = $(id); | |
var inst = this._getInst(target[0]); | |
var date = new Date(); | |
this._setDate(inst,date); | |
this._hideDatepicker(); | |
} | |
$('.dp').datepicker({ | |
showButtonPanel: true | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment