referring URL (where do they come from)

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
qxziw
Forum Newbie
Posts: 1
Joined: Thu Dec 23, 2004 9:09 am

referring URL (where do they come from)

Post by qxziw »

How can I see my visitors referring URL (where do they come from)?? Is there some one that knows a php-page to do that??
I mean something like this site:
http://www.dotz.se/stats/index.asp
check
Where the Visitors came from (max 50)
kenrbnsn
Forum Newbie
Posts: 13
Joined: Tue Jul 01, 2003 3:34 pm
Location: Hillsborough, NJ USA

Post by kenrbnsn »

You can try to use the $_SERVER['HTTP_REFERER'] super global, but remember what is mentioned on the PHP site:
'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.
Post Reply