inchirieri Posted August 4, 2011 Share Posted August 4, 2011 Dear all, I am currently trying to calculate the date difference with a PHP Script. The days are in a calendar control, while the time is in 2 dropboxes (hour/minute). You can see here my demo form. I need the PHP script to return the date in days, using the following formula. If the difference between the dates is **> X days and more than 2 hours**, then the difference is X+1 days, otherwise it's X Days. Could anybody provide a solution please? Quote Link to comment https://forums.phpfreaks.com/topic/243831-php-date-difference-conditional-in-days/ Share on other sites More sharing options...
WebStyles Posted August 4, 2011 Share Posted August 4, 2011 please post the code you already have, and a list of the errors / output you're getting. Quote Link to comment https://forums.phpfreaks.com/topic/243831-php-date-difference-conditional-in-days/#findComment-1251961 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.