Home > Backend Development > PHP Tutorial > php5 Time format issues between PHP4 and PHP5

php5 Time format issues between PHP4 and PHP5

WBOY
Release: 2016-07-29 08:37:22
Original
1135 people have browsed it

PHP5 used on my computer.
PHP4 on the server.
Time on my own machine, 2008-2-14 14:56:29
Write the program and upload it, and it will turn into a string of numbers. 1202972189
Access for database.. Field default value Now()
Solution:
There is no problem. This number is the Unix timestamp, which represents the number of seconds from 1970-1-1 to the present. It generally needs to be formatted and displayed
date('Y-m-d',1202972189)
The result is 2008-02-14

The above has introduced the time format issues of php5, PHP4 and PHP5, including the content of php5. I hope it will be helpful to friends who are interested in PHP tutorials.

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template