Archive of UserLand's first discussion group, started October 5, 1998.
texthitcounter.root -- improvement
Author: Andrew Duncan Posted: 12/29/1999; 8:30:16 AM Topic: texthitcounter.root -- improvement Msg #: 13948 Prev/Next: 13947 / 13949
While playing with texthitcounter.root, I noticed that Netscape doesn't send the referer field for a JavaScript include, but I came up with a workaround that seems to work quite nicely.It's a two-part job. The first part is to use the following macro instead of putting the The second part is also simple. Edit the counter.js script, replacing the two instances of "requestheaders.referer" with "pathargs".
The net result is that the URL of the page containing the {hitcounter()} macro is passed to the counter.js script, which logs the hit against the supplied URL.
I also tested it with iCab 1.8, but since it doesn't currently support JavaScript, it's effectively a noop. I guess this means that there are limits to how accurate the hitcount can be, depending on the browser in question.
You can see an example of this setup at http://web.webwerks.co.nz/ -- look for "Page Views" the very bottom of the page.
There are responses to this message:
- Re: texthitcounter.root -- improvement, William Jones, 12/29/1999; 11:24:45 AM
- Re: texthitcounter.root -- improvement, Ian Thompson, 12/30/1999; 7:08:25 AM
This page was archived on 6/13/2001; 4:53:53 PM.
© Copyright 1998-2001 UserLand Software, Inc.