We page hits counter
Need a relatively small script or two in PHP / MySQL that will let me track visits / hits per individual pages on my website. I want to be able to store in database the number of visitors for each of the pages I attach your script to, and a few important information about a visitor such as location, ip address, server, operating system, etc..
I would also like to be able to filter out robots from potential real visitors, as well as filter out my localhost ip (127.0.0.1) because that is only a testing server.
The connection between each of the mention items does not matter, I just want to store a page in database by its URL, and attach the hits, regional data, etc.. to it.
At the end (in another script / function) I would like to pull out only last, i.e., 10 or 7 days of most visited pages and present them as the "most visited" on my home page.
To recapture what the task is about.
- Need a hit and visitor info per page stored in a MySQL;
- Need to extract most visited (not counting robots and localhost) per a period of time (.e. last 7 days).
Those two tasks should actually be split into to scripts: data storage and data extraction.
PHP, MySQL, HTML