Page 1 of 1

referral page

Posted: Thu Mar 06, 2003 3:28 am
by theclay7
hello

if i have a page, say thispage.php and wants to check where does the previous page comes from, how can i do it???

any php functions? :lol:

Posted: Thu Mar 06, 2003 5:28 am
by volka
http://www.php.net/manual/en/reserved.variables.php#reserved.variables.server
'HTTP_REFERER'
The address of the page (if any) which referred the user agent to the current page. This is set by the user agent. Not all user agents will set this, and some provide the ability to modify HTTP_REFERER as a feature. In short, it cannot really be trusted.

Posted: Thu Mar 06, 2003 5:28 am
by twigletmac
You can look at $_SERVER['HTTP_REFERER'], however:
PHP manual wrote:'HTTP_REFERER'
The address of the page (if any) which referred the user agent to the current page. This is set by the user agent. Not all user agents will set this, and some provide the ability to modify HTTP_REFERER as a feature. In short, it cannot really be trusted.
http://www.php.net/manual/en/reserved.v ... les.server

Mac