Hi,
following the instructions of http://www.chronoengine.com/faqs/64-cfv4/cfv4-using-the-datepicker/3161-how-can-i-select-a-range-of-dates-part-2.html I realized that this script is not compatible with CFV5 J3 because of different use of JQ instead of Mootools.
ask:
how to integrate the script for CFV5
thanks
Cornelio
following the instructions of http://www.chronoengine.com/faqs/64-cfv4/cfv4-using-the-datepicker/3161-how-can-i-select-a-range-of-dates-part-2.html I realized that this script is not compatible with CFV5 J3 because of different use of JQ instead of Mootools.
ask:
how to integrate the script for CFV5
thanks
Cornelio
Hi, Bob
I would like to replicate this your http://greyhead.org/index.php?option=com_chronoforms&tmpl=component&chronoform=linked_datepickers_b wonderful example of range dates but I can not make it work with CFV5. I tried various posts but are unfortunately not able to understand.
currently I have included a function like this
and it works perfectly, but I would use datepicker of CFV5
Thanks in advance
Cornelio
I would like to replicate this your http://greyhead.org/index.php?option=com_chronoforms&tmpl=component&chronoform=linked_datepickers_b wonderful example of range dates but I can not make it work with CFV5. I tried various posts but are unfortunately not able to understand.
currently I have included a function like this
var _MS_PER_DAY = 1000 * 60 * 60 * 24;
// a e b sono oggetti Data
function dateDiffInDays(a, b) {
// Esclude l'ora ed il fuso orario
var utc1 = Date.UTC(a.getFullYear(), a.getMonth(), a.getDate());
var utc2 = Date.UTC(b.getFullYear(), b.getMonth(), b.getDate());
return Math.floor((utc2 - utc1) / _MS_PER_DAY);
}
function getDateDiffInDays() {
var YA = document.getElementById("YA").value
var MA = document.getElementById("MA").value
var DA = document.getElementById("DA").value
var YB = document.getElementById("YB").value
var MB = document.getElementById("MB").value
var DB = document.getElementById("DB").value
var date1 = new Date(YA + "/" + MA + "/" + DA);
var date2 = new Date(YB + "/" + MB + "/" + DB);
var el = document.getElementById("date_diff")
el.innerHTML = dateDiffInDays(date1, date2)
}
and it works perfectly, but I would use datepicker of CFV5
Thanks in advance
Cornelio
Hi Cornelio,
For v5 please check this FAQ:
http://www.chronoengine.com/faqs/70-cfv5/5216-date-control-using-cfv5-date-picker-element.html
Regards,
Max
For v5 please check this FAQ:
http://www.chronoengine.com/faqs/70-cfv5/5216-date-control-using-cfv5-date-picker-element.html
Regards,
Max
This topic is locked and no more replies can be posted.