httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robert Andersson" <rob...@profundis.nu>
Subject Re: [users@httpd] Error 302 5. Redirection Alert.
Date Tue, 21 Oct 2003 14:01:49 GMT
elimachi@datacom.com.bo wrote:
> No, the behavior don not prevail. So the problem may be with
> the script. I`m using php v4.1.2 for Linux RH7.3 and the script is:

May be, just may be?

> if (eregi("index.php", $PHP_SELF)) {
>        Header("Location: index.php");
>        die();
> }

This is bad code, what is it doing here? PHP_SELF is the filename of the
executing script, and if it matches "index.php" this code redirect to
itself, again and again. "Location: index.php" isn't even a valid header, as
I'm pretty sure it requires an absolute URI. By default in PHP 4+, $PHP_SELF
should not be available, either.

If this is your code, go back to: http://www.php.net/manual/en/

If you have taken it from somewhere, complain and/or try to fix it yourself.
It has *nothing* to do with Apache and all with a bad script.

Regards,
Robert Andersson


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message