This article illustrates the simple implementation of PHP's timestamp for today, yesterday, and tomorrow. Share to everyone for your reference, specific as follows:
Echo strtotime (' Now '), ' <br> '//Present
echo strtotime (' Today '), ' <br> ';//The
echo strtotime (' Tomorrow '), ' <br> '//Tomorrow
echo strtotime (' Yesterday '), ' <br> ';//Yesterday
The results of the operation are as follows:
1469674869
1469664000
1469750400
1469577600
Number of seconds remaining today:
echo $time _remain = Strtotime (' Tomorrow ')-time ();
Output: 75531
PS: This site also provides a UNIX timestamp conversion tool, very practical, to provide you with reference to:
Unix timestamp (timestamp) conversion tool:
Http://tools.jb51.net/code/unixtime
More about PHP Interested readers can view the site topics: "PHP date and Time usage summary", "PHP Mathematical Calculation Skills Summary", "PHP Array" operation Skills Encyclopedia, "PHP Data structure and algorithm tutorial", "PHP Programming Algorithm Summary", " PHP Regular Expression Usage summary, "Summary of PHP operations and operator usage", "PHP string (String) Usage summary" and "PHP common database Operation Skills Summary"
I hope this article will help you with the PHP program design.