Counter drops 2-3000 hits then back and forth

In case you have problems with some other PHPJunkyard script (not that there are THAT many).
Post Reply
ksteele
Posts: 3
Joined: Thu Nov 29, 2007 6:19 pm

Counter drops 2-3000 hits then back and forth

Post by ksteele »

Script URL: www.earlybirdstocks.com
Version of script: 1.2
Hosting company: Network Solutions
URL of phpinfo.php: ?
URL of session_test.php: ?
What terms did you try when SEARCHING for a solution: searched all topics within ccounter w/ no luck

Write your message below: Here is a copy of the email I received from my client:

"Hey Kenny -

That counter you found is screwy. It made it over 500,000 on earlybirdstocks but then it lost like 2-3,000, then continued to climb, then it goes down, up etc."

I have checked the current copy of the script against a fresh copy and they haven't changed anything. Any ideas of what may be going on?
Klemen
Site Admin
Posts: 10116
Joined: Fri Feb 11, 2005 4:04 pm

Post by Klemen »

With 500.000+ hits you should use a counter with MySQL database and not one with a text database. The thing is text databases aren't powerful or secure enough for usage on such a large scale, text files can get corrupted too easily.
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
ksteele
Posts: 3
Joined: Thu Nov 29, 2007 6:19 pm

Thats was Quick!!!!

Post by ksteele »

Wow Klemen thanks for the quick reply!!! I don't think they're going to want to pay me to come back and set that up for them. Do you think resetting the hit counter to 1000 will help to resolve this for the time being?
Klemen
Site Admin
Posts: 10116
Joined: Fri Feb 11, 2005 4:04 pm

Post by Klemen »

The problem with overloading text databases is not high count number (50 or 5000 or 500000) but the high number of requests the script must be receiving on that website per day/hour/minute. The counter does use file locking but if it keeps loosing count the database is probably overloaded.

I really recommend finding a MySQL script or you will just have similar problems in the future.
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
ksteele
Posts: 3
Joined: Thu Nov 29, 2007 6:19 pm

Post by ksteele »

Thank you for clearing that up for me and for the time you spend spreading the word.
Post Reply