From: [EMAIL PROTECTED] Operating system: Win32, Unix PHP version: 4.2.1 PHP Bug Type: Session related Bug description: Expires header incorrectly set, cannot be overwritten
When using sessions, the Expires header is set to a date in the past (1981) instead of being correctly calculated from the current date plus the session expire time. This leads to re-loading of the resource instead of using cached data in browsers that obey the Expires header and/or use HTTP 1.0. Additionally, it is not possible to replace the Expires header using the header() function. Trying to do so results in the new correct date being appended after the old incorrect one (separated by a comma) which makes no sense. The only way to achieve correct Cache-Control and Expires headers is to switch off the automatic session headers by calling session_cache_control('none'), and then set all headers on one's own. However, this is only a work-around. -- Edit bug report at http://bugs.php.net/?id=19768&edit=1 -- Try a CVS snapshot: http://bugs.php.net/fix.php?id=19768&r=trysnapshot Fixed in CVS: http://bugs.php.net/fix.php?id=19768&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=19768&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=19768&r=needtrace Try newer version: http://bugs.php.net/fix.php?id=19768&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=19768&r=support Expected behavior: http://bugs.php.net/fix.php?id=19768&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=19768&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=19768&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=19768&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=19768&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=19768&r=dst IIS Stability: http://bugs.php.net/fix.php?id=19768&r=isapi