Re: headers and cookies

From: Date: Wed, 30 Oct 2002 04:24:37 +0000
Subject: Re: headers and cookies
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-121981@lists.php.net to get a copy of this message
This is not correct. Both the setcookie() and header() functions manipulate the HTTP headers in the response. You cannot have output prior to any function that manipulates headers - that's the limitation. These two functions work fine together in any order; it's prior output that will cause an error. Chris Jay Blanchard wrote:
Well, if you send headers first you cannot send cookies, if you send cookies first you cannot send headers.


« previous php.general (#121981) next »