You can put the header function anywhere in the php code as long 
as the logic sends it as the very first output for the page in html. 
Conditional redirects are no problem.

>[EMAIL PROTECTED] (George Pitcher) writes:
>>  Andrew,
>>  I am in a similar position witha Lasso site, which I am considering php-ing.
>>  I need to do conditional redirects.
>>  George P, Edinburgh
>>  ----- Original Message -----
>>  From: "Andrew Penniman" <[EMAIL PROTECTED]>
>>  Sent: Monday, September 10, 2001 3:37 PM
>>  Subject: [PHP] PHP Redirect in the middle of code?
>>  > I am trying to figure out how to use PHP to redirect the user to a new
>>  > location *after* processing and most likely outputting a bunch of code.
>>  > Because this redirection would happen late in the game I can't use
>>  > header("Location: ".$redirect_to);
>You should probably look at ouput buffering; the php manual has a section
>on the subject at http://uk.php.net/manual/en/ref.outcontrol.php and Zeev
>Suraski wrote an article at Zend http://zend.com/zend/art/buffering.php
>   -robin
>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]


    Michael Seely      408-777-9949


Reply via email to