Re: sending header but not leaving page
| From: | Danielle Rijkeboer | Date: | Mon, 05 May 2003 05:56:02 +0000 |
| Subject: | Re: sending header but not leaving page | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-146403@lists.php.net to get a copy of this message | ||
If it were that easy I wouldn't being posting a question because I know how
to simply redirect.. but the problem is that it MUST redirect
while in the loop and then finish the loop.
"John W. Holmes" <holmes072000@charter.net> schreef in bericht
news:000101c3128d$e170f170$7c02a8c0@coconut...
> > 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/
>
>