Click to See Complete Forum and Search --> : Referrer


lord__icon
04-17-2003, 09:27 PM
Ok I am trying to use a Referrer Script
I just what to know what site the user just came from.
I know this does not work in IE3, I have IE5
but every time I try it the messages comes up blank
one more think, the sites are not published so could this be the problem if so is there anouther way
thanks

DrDaMour
04-17-2003, 09:41 PM
from documentation:

JavaScript 1.1. This property is tainted by default. For information on data tainting, see the Client-Side JavaScript Guide.

Description
When a user navigates to a destination document by clicking a Link object on a source document, the referrer property contains the URL of the source document.

referrer is empty if the user typed a URL in the Location box, or used some other means to get to the current URL. referrer is also empty if the server does not provide environment variable information.

Examples
In the following example, the getReferrer function is called from the destination document. It returns the URL of the source document.

function getReferrer() { return document.referrer}


edit:
sorry dave, didn't see you already answered that