in reply to Site Statistics using $ENV{'HTTP_REFERER'}

I don't know if you've considered this and rejected for some other reason, but somewhere on your web server, in a dir probably called logs there shd be a file called something like access.log, and that likely has the same info you get from $ENV{'HTTP_REFERER'} for all the files called from your server, including index.html. Then all you need is a perl app to parse the file and throw you the results :). (But I see this is part of a longer inquiry, and if this sounds like I'm teaching my grandmother to suck eggs then I apologise.)

§ George Sherston