Forum Moderators: coopster
You can try to keep track by using the javascript onclose function to route your visitors through an exit page, but that will get pretty complicated pretty fast.
You'd probably do best to settle for a tally of the number of visitors who have been served a page in the last 5 or 10 minutes.
I'm a novice at PHP so I will leave the details to others, but I would think one approach would be to write each visitor's IP address to a file along with the current timestamp. Then you could have a routine that reads the file, filters out any that are over the limit of 5 or 10 minutes, and writes it out again, tallying the unique IP addresses in the process.
If you do keep your own log, make sure that you include some mechanism for clearing out stale entries. Otherwise your log file will grow forever, and eventually you'll be taking a noticable ammount of time just to parse it at each page load.