which function used to get the number of days between two
given dates in php



which function used to get the number of days between two given dates in php..

Answer / silambu_irtt

<?php
$days = (strtotime("2005-11-26") - strtotime("2005-11-20"))
/ (60 * 60 * 24);
print $days;
?>
This code print number of days between two dates

Is This Answer Correct ?    12 Yes 1 No

Post New Answer

More PHP Interview Questions

How do you execute a php script from the command line?

0 Answers  


What is binary safe function in php?

0 Answers  


what is the default session expire time in php? what is default file attachment size in mail in php?

3 Answers  


How to get the DNS servers of a domain name?

1 Answers   Life Infotech,


Does wordpress still use php?

0 Answers  


What are the different components used in php for formatting?

0 Answers  


What is php resource type?

0 Answers  


What is x+ mode in fopen() used for?

0 Answers  


What is lamp in php?

0 Answers  


How to use http headers inside php?

0 Answers  


How do you debug php?

0 Answers  


How to return a value back to the function caller?

0 Answers  


Categories