Re: HTTP redirects, Location: header, and IE5 problems
| From: | Jason Brooke | Date: | Wed, 27 Sep 2000 06:17:29 +0000 |
| Subject: | Re: HTTP redirects, Location: header, and IE5 problems | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-17716@lists.php.net to get a copy of this message | ||
I'm not seeing the behaviour you're describing, and none of my clients
are complaining about it either
<? header("Location: http://www.php.net") ?>
for example, works fine
for me in various versions of IE, including 5.01 and 5.5
Try http://jason.qgl.org/redirect.html - it
contains the above bit of
php
jason
> I have been frustrated recently working with IE5.01+ and
> HTTP redirects. In PHP, these are most easily done with
> the header("Location: $url"); call, which magically updates
> the HTTP return code and everything. :-)
>
> So the problem is that Internet Explorer v. 5 and above
> are just returning Error - Page Not Found when given data
> like this. What is going on?
>
> At present, it looks to me like the problem is that IE5.01
> and IE5.5 are set to default not to honor the HTTP/1.0 spec,
> and take absolute URLs in the Location header. Instead,
> they display an error. If they are given a *relative* URL,
> then they are OK.
>
> Can anyone confirm this as a general observation, or even
> more specifically? Can IE5 be set not to ignore the specification
> for HTTP headers? I have observed this broken behavior with
> IE5.5 on two other sites besides those of mine which try to
> do redirects. One looks like it uses Python to issue redirects
> and the other uses Perl, so I think this is an issue with Explorer.
>
> As a workaround, Netscape seems to accept relative
> paths in the Location header, so that is the indicated
> thing. (I guess if you want to do off-site redirects, you
> have to find some other mechanism. Perhaps the
> HTTP/1.1 Content-location header? I'm not sure...)
>
> -Greg Billock