mktime()使用date()夏令时知道吗?

mktime()使用date()夏令时知道吗?

问题描述:

我在s.o上已阅读了有关此问题的几个问题.而且似乎都没有人直率地问或回答这个问题:

I've read through a few questions about this here on s.o. and none seem to ask or answer the question very bluntly:

$ts_today = mktime( 0, 0, 0, date('m'), date('d'), date('Y') );

这个夏令时知道吗?

如果没有,我如何使mktime()意识到夏令时?

if not, how do i make mktime() daylight saving aware?

〜关于 the PHP网站本身,以及一些有用的示例.简而言之,较新版本的PHP将DST作为时区处理功能的一部分考虑在内

~There's plenty of discussion of this on the PHP site itself, and some useful examples. In short, newer versions of PHP take account of DST as part of the timezone handling functionality