On Wed, 25 Jul 2001 07:30:03 -0600, [EMAIL PROTECTED] (Nelson
Goforth) wrote:
>I just want to open another page, sending some parameters, at a point 
>in a script - without the user clicking on anything (I can do this in 
>a form - I want to do it WITHOUT the form).
>Like:    if($test) {
>               GO_TO_PAGE (http://www.site.dom/page.php?id=838383);
>          }
>Except with code that actually works, of course.
>I tried "header (Location:...)" but got an error message that I can't 
>add to the headers.

to clarify:

so while the script is running (ON THE SERVER, it has not yet arrived
at the client browser), there are several logic paths and some of them
don't involve you printing anything to the browser, instead you just
want to jump to another site/page.

OK.  the simplest solution is to redirect as you've tried above.  if
that doesn't work then the reason is, you've already printed
something out to stdout and once you've done that you can't
send headers anymore.  to work around this, you would use
the output buffering functions:


there are other workarounds, but that's the simplest.


PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to