From: [EMAIL PROTECTED] Operating system: Linux/LFS 2.4.17 PHP version: 4.0.6 PHP Bug Type: Date/time related Bug description: date and gmdate don't return correct RFC 822 string
RFC 822 specifies the date string in chapter 5.1 as date = 1*2DIGIT month 2DIGIT 2DIGIT is defined to be "exactly <n> occurrences of (element). Thus 2DIGIT is a 2-digit number" [chapter 2.6]. PHP however returns the day value as one digit only, e.g.: Fri, 8 Mar 2002 10:33:37 +0000 This might seem to be a minor issue but actually makes date("r") or gmdate("r") unusable with software that expects two digit days. The Apache server is probably the most important one: creating a conditional request like "If-Modified-Since: " . gmdate("r",$lastmtime) will for example not work. It will not fail, but Apache won't recognize this date and always return the file, modified or not. (And yes, Apache's behaviour should be modified, too, making it less picky) -- Edit bug report at http://bugs.php.net/?id=15952&edit=1 -- Fixed in CVS: http://bugs.php.net/fix.php?id=15952&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=15952&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=15952&r=needtrace Try newer version: http://bugs.php.net/fix.php?id=15952&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=15952&r=support Expected behavior: http://bugs.php.net/fix.php?id=15952&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=15952&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=15952&r=submittedtwice