javascript - How to set tomorrow as default value in dropdown calendar -
i dont solution yet problem, reservation code set today default value, how can set tomorrow default value? pls help? code shoul alter code below
function ccheckdateorder(g, c, b, h, e) { var one_day = 1000 * 60 * 60 * 24; var j = cdom.cgetparentorself(g, "form"), k, l = new date(0), = new date(0), a, f = new date(); if (j[c].value !== "0") { l.setdate(j[c].value); } if (j[b].value !== "0") { k = j[b].value.split("-"); l.setfullyear(k[0]); l.setmonth(k[1] - 1); } l.sethours(12); l.setminutes(0); l.setseconds(0); if (j[h] != undefined && j[h].value !== "0") { i.setdate(j[h].value); } if (j[e] != undefined && j[e].value !== "0") { k = j[e].value.split("-"); i.setfullyear(k[0]); i.setmonth(k[1] - 1); } i.sethours(12); i.setminutes(0); i.setseconds(0); if (j[b].value !== "0") { while (l.getmonth() != j[b].value.split("-")[1] - 1) { l.setdate(l.getdate() - 1); j[c].value = l.getdate(); } var d = l.getmonth() + 1; j[b].value = l.getfullyear() + "-" + d; } var days_diff = ((l - i) / one_day); if (days_diff >= (1 - minimum_nights)) { i.settime(l.gettime() + minimum_nights * date.prototype.milliseconds_per_day); = i.getmonth() + 1; if (j[c].value !== "0") { if (j[h] != undefined) j[h].value = i.getdate(); } if (j[b].value !== "0") { if (j[e] != undefined) j[e].value = i.getfullyear() + "-" + a; } } cupdatedaysinddl(); }
javascript datepicker
No comments:
Post a Comment