...

View Full Version : users online using databases



Blatch
09-02-2009, 09:34 PM
I want to write this out, and I'm sure I can but I struggle with timestamps.

I can write insert unique users with ip, timestamp, etc to a db, but how can I remove them after a set amount of time. I know I would need timestamps, but I can't figure out what exactly to do.

Any help appreciated :)

oracleguy
09-02-2009, 09:54 PM
After you are done adding a new row, run a delete SQL query that removes any rows with a timestamp older than whatever time period you desire.

Blatch
09-04-2009, 05:35 AM
Thanks, seems so simple lol. Don't know why I couldn't figure that out.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum