Home > Backend Development > PHP Tutorial > PHP 如何获取当前某个时间 当天的时间戳

PHP 如何获取当前某个时间 当天的时间戳

WBOY
Release: 2016-06-06 20:40:28
Original
1160 people have browsed it

PHP 如何获取当前某个时间 当天的时间戳。

回复内容:

PHP 如何获取当前某个时间 当天的时间戳。

<code><?php // http://3v4l.org/AvdDZ
$d = new DateTime("7:00", new DateTimeZone("Asia/Shanghai"));
echo $d->format("Y-m-d H:i:s");
</code>
Copy after login

echo strtotime("+100 days");

<code>mktime($hour, $minute, $second, $month, $day, $year);
</code>
Copy after login
Related labels:
php
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