asp hit counter

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • wmtr3110
    New Member
    • Feb 2008
    • 1

    asp hit counter

    Hi,

    I'm a little new with the asp code so please bare with me. I am seeking to find a hit counter to be placed on an internal website @ my company. I've looked @ some hit counters online that have been free; however, when they ask me to register, they ask for a link to the website. For obvious reasons the counter can't work because the website resides internally. Where can I go to get a free hit counter that will provide statistics such as IP address, PC name, userID, etc? Thanks in advance for the help.
  • markrawlingson
    Recognized Expert Contributor
    • Aug 2007
    • 346

    #2
    You'll find that most of the experts and developers in general on this website don't use tools like free hit counters. The reason is primarily because this is a developer forum so we do almost everything ourselves - but also because it's incredibly easy to program your own stat counter.

    There are many ways to do it, personally I prefer a database based statistics counter because i record a ton of information when a user logs onto my site. Everything from how long they were there each time, to the average time they've spent on the site, to their ip address, browser version, how many times they've come to the site, the average page hits per visit, their HTTP referrer (the website they were at before they came to mine) - etc etc etc.

    However if all you need is a count of how many visits your site has tallied.. you can use a simple xml document or txt document to store the data. A lot of people even just use an application object (not a good idea though, if the server is rebooted or the worker process dies you lose the info)

    If you're interested in doing it yourself we can provide some examples for you.

    Sincerely,
    Mark

    Comment

    • jhardman
      Recognized Expert Specialist
      • Jan 2007
      • 3405

      #3
      Originally posted by markrawlingson
      However if all you need is a count of how many visits your site has tallied.. you can use a simple xml document or txt document to store the data. A lot of people even just use an application object (not a good idea though, if the server is rebooted or the worker process dies you lose the info)
      Yeah, I tried it with an application object when I was new (8 or 9 years ago) and it was a bad idea. Sure it was easy to code, but the counter seemed to reset nearly every day. XML isn't much harder, though, and is very stable.

      Jared

      Comment

      • markrawlingson
        Recognized Expert Contributor
        • Aug 2007
        • 346

        #4
        Totally, very silly idea :P Yet most of the tutorials online that explain how to do this use application variables... without any mention of the billion and one things that could go wrong that would cause the data in the application object to be erased..

        Sincerely,
        Mark


        Originally posted by jhardman
        Yeah, I tried it with an application object when I was new (8 or 9 years ago) and it was a bad idea. Sure it was easy to code, but the counter seemed to reset nearly every day. XML isn't much harder, though, and is very stable.

        Jared

        Comment

        Working...