write code to find the date difference b/w two given date
using PHP not MYSQL function?
Answer Posted / rameshfromind
There is one function for gregoriantojd that means convert
to gregorian calendar date to julian date count.
Below the example for counting days between two date.
<?
$startDate = '01-01-2008' // mm-dd-yyyy/yy
$endDate = '01-30-2008' // mm-dd-yyyy/yy
echo gregoriantojd($endDate) - $gregoriantojd($startDate);
?
// OUTPUT
29
Is This Answer Correct ? | 9 Yes | 9 No |
Post New Answer View All Answers
What are traits?
Write down the code for save an uploaded file using php?
Why do we need session?
What is the use of header() function in PHP? What the Limitation of HEADER()?
Is php easier than node?
Do you know what's the difference between __sleep and __wakeup?
Tell me how is it possible to return a value from a function?
What is the use of count() function in php?
Where is the functions php in wordpress?
Where do I run php code?
Tell me what is the use of "ksort" in php?
How to list all values of submitted fields?
Which will check if a function exists?
Explain me difference between mysql_connect and mysql_pconnect?
What is scope of variable in php?