$(function() {
$("#datepicker").datepicker();
$("#datepicker").val();
$("#datepicker").on("change",function(){
var selected = $(this).val();
alert(selected);
});
});
var d = $('div#someID').datepicker('getDate');
document.getElementById("revised_on").value = new Date().toJSON().slice(0, 10);
if(this.selected){
console.log(this.selected.endDate.format("DD-MMMM-YY"); // need to show date in DD-MMMM-YY Format
}