|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2004-11-03 20:58 UTC] derick@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Tue Dec 16 22:00:01 2025 UTC |
Description: ------------ Halloween, according to strtotime(), is both Sunday and Monday this year. I haven't checked other years, but I just ran into this. Uh... that's all I've got for you. Reproduce code: --------------- echo("<p>"); echo(date("d_M_y",mktime(0,0,0,10,30,04))); echo("</p><p>"); echo(date("d_M_y",strtotime("tuesday",mktime(0,0,0,10,30,04)))); echo("</p><p>"); echo(date("d_M_y",strtotime("monday",mktime(0,0,0,10,30,04)))); echo("</p><p>"); echo(date("d_M_y",strtotime("sunday",mktime(0,0,0,10,30,04)))); echo("</p>"); Expected result: ---------------- 30_Oct_04 02_Nov_04 01_Nov_04 31_Oct_04 Actual result: -------------- 30_Oct_04 01_Nov_04 31_Oct_04 31_Oct_04