From: admin at yawnster dot com Operating system: WinXP PHP version: 5.1.2 PHP Bug Type: Date/time related Bug description: gmdate returning March twice under 'F' through a loop.
Description: ------------ The gmdate() function produces March twice and misses out October under certain conditions. Reproduce code: --------------- <div id="month"> <select name="month"> <?php for($i = 1; $i <=12; $i++) { $date = gmdate('F', mktime(0, 0, 0, $i, 1, 2006)); echo("<option value='$i'>$date</option>"); } ?> </select> </div> Expected result: ---------------- Well it should produce a list of the Months in order into a drop-box. Actual result: -------------- Well it gives out the 12 months, but goes through March Twice, but misses out October.. This problem however doesnt occur within the date() function, so for the time being I'll use this.. -- Edit bug report at http://bugs.php.net/?id=36748&edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=36748&r=trysnapshot44 Try a CVS snapshot (PHP 5.1): http://bugs.php.net/fix.php?id=36748&r=trysnapshot51 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=36748&r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=36748&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=36748&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=36748&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=36748&r=needscript Try newer version: http://bugs.php.net/fix.php?id=36748&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=36748&r=support Expected behavior: http://bugs.php.net/fix.php?id=36748&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=36748&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=36748&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=36748&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=36748&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=36748&r=dst IIS Stability: http://bugs.php.net/fix.php?id=36748&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=36748&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=36748&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=36748&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=36748&r=mysqlcfg