M
Mike.Duffy
Is there a trick you can use to know if someone has made your web page his
"home"? At first, I thought to check if ( history.length == 0 ) or if (
document.referrer.href == ""). [1]
These both sort of work, but can be fooled if the browser is launched from
another application, such as an external mail reader or newsreader.
[1] = Document.referrer is always empty for local disk "file://" urls. This
method will also be fooled if someone takes the time to type in (or
cut/paste) the url directly into the address bar.
"home"? At first, I thought to check if ( history.length == 0 ) or if (
document.referrer.href == ""). [1]
These both sort of work, but can be fooled if the browser is launched from
another application, such as an external mail reader or newsreader.
[1] = Document.referrer is always empty for local disk "file://" urls. This
method will also be fooled if someone takes the time to type in (or
cut/paste) the url directly into the address bar.