开发者

Calculating future date with strtotime doesn't work properly

If I run "next saturday" into strtotime function it shows 4/3/2010 as the date. Why does it n开发者_JAVA百科ot show 4/10?


Other Timezones

date_default_timezone_set("Etc/GMT-5");
$time = strtotime('Saturday +7 day');
$date = date("m/d/Y",$time);


try:

ini_set('date.timezone', 'America/Los_Angeles');

or edit your php.ini


got it ...

strtotime('next Saturday', strtotime('+1 day'));
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜