RE: [PHP] sending header but not leaving page
| From: | John W. Holmes | Date: | Sun, 04 May 2003 22:38:22 +0000 |
| Subject: | RE: [PHP] sending header but not leaving page | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-146384@lists.php.net to get a copy of this message | ||
> I want to send header information but I don't want to leave my page
> because
> it still has to finish a loop.
> This is what my code looks like:
>
> function send($userid,$developerid,$gsm,$text,$sender)
> {
> $filename =
> "http://www.website.com/folder/page.cgi?userid=$userid;
> header =("location: "$filename");
> }
>
> This function is called from another page while in a loop and it has
to
> finish that loop after sending the header info.
Just set a flag that you want to redirect and do it after your loop.
Your logic is all screwy the way it is.
---John W. Holmes...
PHP Architect - A monthly magazine for PHP Professionals. Get your copy
today. http://www.phparch.com/