开发者

strtotime bug with recognizing last month

echo strtotime("first day of last month");

returns 1317492376but it's 6开发者_运维技巧 pm of 1 september! Shouldn't it return the timestamp of first second of the month? If not, how to get it?


strtotime() doesn't touch the time part when you specify only the date. Try this:

strtotime( "first day of last month 00:00" ) 
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜