i have a javascript code to create an extra button in the datepicker panel when clikced on the input filed.
$(function() {
$( ".datepicker" ).datepicker({ dateFormat: "yy-mm-dd",
changeMonth: true,
changeYear: true,
yearRange: "2014:2034",
showButtonPanel: true,
beforeShow: function (input) {
setTimeout(function () {
var buttonPane = $(input)
.datepicker("widget")
.find(".ui-datepicker-buttonpane");
var btn = $('<button class="ui-datepicker-current ui-state-default ui-priority-secondary ui-corner-all" type="button">CSA</button>');
btn.unbind("click")
.bind("click", function () {
//$.datepicker._clearDate(input);
//alert('custom text');
$(input).datepicker("hide");
$(input).val("0000-00-00");
});
btn.appendTo(buttonPane);
}, 1);
}
});
});
Now when i click the extra button "CSA" in the panel, 0000-00-00 appears. Now what i want to is that when the button "CSA" is clicked the date off today + 6 months to appear. Is that possible in datepicker?