Find the number of days between 2 dates. code example
Example: javascript get seconds between two dates
var secondBetweenTwoDate = Math.abs((new Date().getTime() - oldDate.getTime()) / 1000);
var secondBetweenTwoDate = Math.abs((new Date().getTime() - oldDate.getTime()) / 1000);