Get First Day from Request:
$originalDate = $_REQUEST[‘date’];
$newDate = date(“Y-m-d”, strtotime($originalDate));
Get Second Day from Request:
$endDate = $_REQUEST[‘date2’];
$toDate = date(“Y-m-d”, strtotime($endDate));
Get Difference between days:
$date_diff = (strtotime($toDate)- strtotime($newDate))/24/3600;
How useful was this post?
Click on a star to rate it!
Average rating / 5. Vote count:
No votes so far! Be the first to rate this post.