Web Hosting Talk







View Full Version : Need Counter Help


paulg1981
01-08-2008, 10:19 AM
Hello All,
This is my first post in Programming so be gentle :-)

I have been looking all over the place trying to find a counter script that tracks unique visits and displays graphical count. The only catch is that I want it to count ip's once every 24 hours instead of once ever. I have found many counter scripts here and other places but none do both.

If anyone has a canned script or wrote one themselves they would be willing to share it would be greatly appreciated! Thanks and and have a good one!

paulg1981
01-09-2008, 12:07 PM
I have found a script that I like written in php. The only problem is that the uniques hits are counted only once instead of every 24 hours. I believe I can modify it to flush the .db file every day.

Do someone know where to point me to learn the code to empty a .db file in php?

Would just deleting the file work? I understand that fopen creates the file specified if it does not exist?

if ($date != date("Y m d")) {
unlink($file_ip);
}

Anybody? Am i on the right track here?