mercredi 8 avril 2015

Add 5 hours for current time in date time picker jquery 1.10.1


Vote count:

0




i am using http://ift.tt/1GnZJ0Q in that i am going to add 5 hours for end time i have tried but it is not working properly.and one more dought that why this code not working in jquery 1.7.2 .thank you



jQuery(function () {
jQuery('#startDate').datetimepicker();
jQuery('#endDate').datetimepicker();
jQuery("#startDate").on("dp.change",function (e) {
jQuery('#endDate').data("DateTimePicker").setMinDate(e.date);
});
jQuery("#endDate").on("dp.change",function (e) {
var d1=new Date();
var d2=new Date(d1);
var addedhour=d2.setHours(d1.getHours()+5);
datetext=datetext+" "+d2.getHours()+": "+d2.getMinutes();
jQuery('#startDate').data("DateTimePicker").setMaxDate(e.date);
});
});


asked 35 secs ago







Add 5 hours for current time in date time picker jquery 1.10.1

Aucun commentaire:

Enregistrer un commentaire