Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.php > #7829

Re: Dynamic redirect - losing variable

Message-ID <2832974.UPYZDPpjPl@PointedEars.de> (permalink)
From Thomas 'PointedEars' Lahn <PointedEars@web.de>
Organization PointedEars Software (PES)
Date 2012-12-18 00:54 +0100
Subject Re: Dynamic redirect - losing variable
Newsgroups comp.lang.php
References <20d8e05a-6cb1-4b19-8b2f-58346c116352@googlegroups.com> <kao6fb$otm$1@speranza.aioe.org>
Followup-To comp.lang.php

Followups directed to: comp.lang.php

Show all headers | View raw


Christoph Becker wrote:

> budatlitho wrote:
>> I'm struggling with adding to a redirect url - I lose the $id value. What
>> am I missing? THANKS in advance.
>> 
>> $redirect_url = "<meta http-equiv='refresh'
>> content='1;URL=http://www.districtnine.org/login.php?id='".$id." />";
>> echo $redirect_url;
> 
> You're excluding the $id from the value of the "content" attribute. Try:
> 
> $redirect_url = "<meta http-equiv='refresh'
> content='1;URL=http://www.districtnine.org/login.php?id=".$id."' />";
> 
> You might consider to do the redirect "directly" by sending the
> appropriate "Location" HTTP response header, instead of letting the
> browser do the redirect.

No, they definitely SHOULD: <www.w3.org/QA/Tips/reback>


PointedEars
-- 
> If you get a bunch of authors […] that state the same "best practices"
> in any programming language, then you can bet who is wrong or right...
Not with javascript. Nonsense propagates like wildfire in this field.
  -- Richard Cornford, comp.lang.javascript, 2011-11-14

Back to comp.lang.php | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Dynamic redirect - losing variable budatlitho@gmail.com - 2012-12-17 14:23 -0800
  Re: Dynamic redirect - losing variable Christoph Becker <cmbecker69@gmx.de> - 2012-12-17 23:32 +0100
    Re: Dynamic redirect - losing variable Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2012-12-18 00:54 +0100
    Re: Dynamic redirect - losing variable budatlitho@gmail.com - 2012-12-18 06:44 -0800

csiph-web