Thanks Gordon, I'll put a link in, just in case. It certainly can't hurt.
----- Original Message ----- From: "Gordon Stewart" <[EMAIL PROTECTED]> To: <[email protected]> Sent: Sunday, August 21, 2005 12:39 AM Subject: Re: [php-list] header refresh > On 8/21/05, Bob <[EMAIL PROTECTED]> wrote: >> Is it safe to use: >> header("refresh: 0; url=http://www.website.com/page1.php"); >> >> Googling for it produces mixed results. >> Some say it's ok and others say it's unreliable? > > From what I know - If you use the HTML equivelant, - you are hoping > that the persons browser will correctly interpret the command & > re-direct the page.... > > Doing it in PHP - The command is sent before any HTML output, & the > actual Server re-directs the person.... - Before it (HTML) gets to the > persons browser / screen... > > Therefore (of little I know of this) - I think it works well.. > > BUT - To be sure - You might want to do this :- (i'll assume you have > put the header command in an IF statement - When a certain condition > is met...) > > > header("refresh: 0; url=http://www.website.com/page1.php"); > echo "<HTML> > <BODY> > <FONT COLOR='red'>Error</FONT> > <BR><BR> > > Please click <A HREF='http://www.website.com/page1.php'>this link</A> > to contrinue. > > <BR><BR> > > </BODY></HTML>\n"; > exit; > > (change the text as necessary...) > > For anyone that isnt re-directed - It will show the text / link - to > continue.... > > > -- > G Stewart > http://e-services.kwister.com/ > NZ community groups - [EMAIL PROTECTED] ------------------------ Yahoo! Groups Sponsor --------------------~--> <font face=arial size=-1><a href="http://us.ard.yahoo.com/SIG=12he0hqpq/M=362329.6886308.7839368.1510227/D=groups/S=1705005703:TM/Y=YAHOO/EXP=1124594439/A=2894321/R=0/SIG=11dvsfulr/*http://youthnoise.com/page.php?page_id=1992 ">Fair play? Video games influencing politics. Click and talk back!</a>.</font> --------------------------------------------------------------------~-> Community email addresses: Post message: [email protected] Subscribe: [EMAIL PROTECTED] Unsubscribe: [EMAIL PROTECTED] List owner: [EMAIL PROTECTED] Shortcut URL to this page: http://groups.yahoo.com/group/php-list Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/php-list/ <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/
