1function dateDiff() {
2
3 var date1 = new Date(document.getElementById("fromDatePicker").value);
4 var date2 = new Date(document.getElementById("toDatePicker").value);
5 var difference = date2 - date1;
6 var days = difference/(24*3600*1000);
7 document.getElementById('hari').value=days;
8 }