[thelist] header:location and $http_referer in php

Hans Zaunere zaunere at yahoo.com
Mon Mar 25 08:36:01 CST 2002


This might be a PHP configuration issue or a browser
issue.  If register_globals is not enabled (as it
should be) you'll need to access this variable by
$HTTP_SERVER_VARS['HTTP_REFERER'] in versions previous
to 4.1.0, or $_SERVER['HTTP_REFERER'] in later
versions.

Also, some browsers just don't set this variable
correctly, and it should not be trusted.  I would pass
something in the URL, etc.

Hans Z
New York PHP
http://nyphp.org


--- Salagean Catalin <cds at orizont.net> wrote:
> This is a multi-part message in MIME format.
> --
> [ Picked text/plain from multipart/alternative ]
> I'm using header("Location:http://B") to redirect
> the visitor from site A to site B. In site B I wanna
> use $HTTP_REFERER to find out the adress from wich
> the visitor came, but it's not working,
> $HTTP_REFERER gives me an empty string. Is there a
> problem with my setup(Apache 1.3.23 on Win XP), or
> I'm just doing this completely wrong? In this case,
> what can I do to redirect the user, without passing
> some information in the url?
>
> Catalin
>
> --
>
> --
> For unsubscribe and other options, including
> the Tip Harvester and archive of thelist go to:
> http://lists.evolt.org Workers of the Web, evolt !


__________________________________________________
Do You Yahoo!?
Yahoo! Movies - coverage of the 74th Academy Awards®
http://movies.yahoo.com/



More information about the thelist mailing list