Home > Backend Development > PHP Tutorial > 时间戳怎么转换

时间戳怎么转换

WBOY
Release: 2016-06-13 12:57:31
Original
1201 people have browsed it

时间戳如何转换
如题:如何在系统当前的时间上  再加上 1天14小时24分 的时间, 然后对数据以进行储存到数据库 int类型?    是用这种方式吗? php  strtotime     那么这段php如何写?


------解决方案--------------------
echo date ( "Y-m-d H:i:s", strtotime ( date('Y-m-d H:i:s') . "+1 days, +14 hours, +24 minutes" ) );
Copy after login

------解决方案--------------------
strtotime('+1 day +14 hours + 24 minutes');

------解决方案--------------------
噗,还是版主的代码简洁
------解决方案--------------------
引用:
strtotime('+1 day +14 hours + 24 minutes');

原来还可以这么用。

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