Re: header redirection
| From: | Steve Edberg | Date: | Fri, 14 Sep 2001 20:37:47 +0000 |
| Subject: | Re: header redirection | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-67410@lists.php.net to get a copy of this message | ||
It's my understanding that PHP's normal behavior IS to send the header when it is encountered in your program, and then continue running the program (unless you have an exit statement after the header).
Perhaps you have output buffering turned on?
If that's not the case, please most more info, and perhaps the relevant parts of the script if possible.
By the way, I'm pretty sure you don't need those trailing newlines ("\n\n") there; PHP takes care of that for you. I don't know if that's the source of your problem or not...
-steve
At 12:59 PM -0400 9/14/01, Poppy Brodsky wrote:
does not execute until the remainder of the script has executed....... How can I redirect the user: header("Location: http://www.foo.bar\n\n"); and continue to execute a set of commands after the redirection? Just having the redirection code before the other code does not work. Linux running apache and php4 poppy-- +------------------------ Open source questions? ------------------------+ | Steve Edberg University of California, Davis | | sbedberg@ucdavis.edu Computer Consultant | | http://aesric.ucdavis.edu/ http://pgfsun.ucdavis.edu/ | +----------- http://pgfsun.ucdavis.edu/open-source-tools.html -----------+