Wife/Girlfriend/Sister?
Pepper Spray &
Stun Gun Specials!
KEEP THEM SAFE.
 CoverYourASP --> Storing statistics

Free membership

Join in the fun! Sign in
Member Services

Site navigation
Download the entire site!
Search my articles
Free Magazines
Browse the directory

Send me feedback
Buy my boxer shorts

Recommend this page
Printer-friendly page

Resources I recommend
Link to my site
Advertising slashed!
About your privacy
Legal stuff
Site statistics
82 active users
2558 visitors today
5062 pages today
how is this done?
Tools I use

CoverYourASP
Copyright © 1999-2010 James Shaw.
All rights reserved.

ASP.NET Blog
RSS submissions
E-commerce

Now open source with SourceForge!

The story so far...

I've always used SiteMeter to store statistics about you, my readers. It was very simple to implement, but recently too many people have been commenting how "unprofessional" it looks to have a hit counter.

Now, although I don't agree it's unprofessional, I did think it would be fun to write my own version.

The simple specifications were:

  • To be accessed through an <img> tag
  • To store the page being viewed, the referring page, the readers IP address, browser and screen width.
  • To cope as well as possible with client-side script disabled

As it turned out, this was quite easy. I'm storing the information in my handy Access database, so you can view the raw data or see sample reports.

To be honest, with this latest addition I'm now worried about how Access will cope with the strain. This table will get very large, very quickly. Time to break open that fresh SQL Server 2000 DVD...

Part 2: The Footer script...

Featured sponsor
My favorite resources

Tiki Statues - Tiki Masks - Tiki Totems



See my source code
wherever you see this icon...

You can also download the entire site source code for FREE!

CoverYourASP Mugs, T-shirts, caps - even Boxer shorts...
I don't make a penny from these, but they're a lot of fun! Don't you need a new mouse mat?