View Single Post

  #13 (permalink)  
Old 05-09-2008
Erwin Moller
 
Posts: n/a
Default Re: How to detect user leaving site?

sebastian schreef:
>> Regards,
>> Erwin Moller

>
> Something tells me that you are not, in fact, Erwin Moller. If not,
> please do not reply to my posts. The fact that you would masquarade as
> another user is ridiculous. Pitiful.
>
> - Sebastian
>


Hi Sebastian,

Was my answer so darn stupid that you confused me with that
imposternoob? And yes, masquarading as another user is totally stupid.
I still have no clue why that happened, but the guy seems away now.
I hope it stays that way.

Anyway, to the original subject: I still fail to see the use of using
the referer header.

For clearity's sake, this is what I found from w3c.

from http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html
Quote:
14.36 Referer

The Referer[sic] request-header field allows the client to specify, for
the server's benefit, the address (URI) of the resource from which the
Request-URI was obtained (the "referrer", although the header field is
misspelled.) The Referer request-header allows a server to generate
lists of back-links to resources for interest, logging, optimized
caching, etc. It also allows obsolete or mistyped links to be traced for
maintenance. The Referer field MUST NOT be sent if the Request-URI was
obtained from a source that does not have its own URI, such as input
from the user keyboard.

Referer = "Referer" ":" ( absoluteURI | relativeURI )

Example:

Referer: http://www.w3.org/hypertext/DataSources/Overview.html
So what is IN the referer header?
(If it is set by the browser, and not stripped by some router as Jerry
already warned for)
Well, nothing more that the URI of the page that contained the url you
are visiting now.
IF that URL is on another site (domain), the fact that it is clicked
will never reach the original server.

So I still don't see how this can be used to detect that a user is
leaving your site. Yes, of course the second server can see it, when the
right referer header is sent, but NOT the server of the OP.

Or am I missing something completely here?

Regards,
Erwin Moller

PS: I read the only goal of this exercise was to say 'welcome back'. A
simple cookie might make more sense to do that.
Reply With Quote