#33597 [Opn->Fbk]: setcookie expires date format

From: Date: Wed, 06 Jul 2005 23:04:52 +0000
Subject: #33597 [Opn->Fbk]: setcookie expires date format
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-81502@lists.php.net to get a copy of this message
 ID:               33597
 Updated by:       tony2001@php.net
 Reported By:      rodricg at sellingsource dot com
-Status:           Open
+Status:           Feedback
 Bug Type:         Unknown/Other Function
 Operating System: Linux
 PHP Version:      5.0.4
 New Comment:

Please try using this CVS snapshot:

  http://snaps.php.net/php5-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5-win32-latest.zip




Previous Comments:
------------------------------------------------------------------------

[2005-07-07 00:20:20] rodricg at sellingsource dot com

Description:
------------
setcookie expires date format is invalid according to  
http://wp.netscape.com/newsref/std/cookie_spec.html
 
and  
http://www.faqs.org/rfcs/rfc2109 
 
ie. " ... and the separators between the elements of the 
date must be dashes." 
  
 

Reproduce code:
---------------
<?php

setcookie("TestCookie", "PeanutButter", time()-3600);

?>

Expected result:
----------------
Should generate a header with an expires date like: 
 
expires=Wed, 06-Jul-2005 20:49:30 GMT 

Actual result:
--------------
Generates a header with an expires date like: 
 
expires=Wed, 06 Jul 2005 20:49:30 GMT 


------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=33597&edit=1


Thread (6 messages)

« previous php.bugs (#81502) next »