Anyone know? do i really need to create a new table which will store logged on members?
I would appreciate if someone had a better way.
Best Regards
Trevors
| SitePoint Sponsor |
Anyone know? do i really need to create a new table which will store logged on members?
I would appreciate if someone had a better way.
Best Regards
Trevors
That way worked for me..
I overrided the default session handlers to work from a mysql tabel. So this is the place where all my sessions are stored..
Evert





I typically use a table to store logged on users. I update this table with the timestamp on their every page load. I also run a universal garbage collection script to log out inactive users whose timestamp is greater than, say, 20 minutes old. This kills old sessions and help maintain an accurate count of logged on users.
That's also how I did it.
if made a small script that generates a random number between 1 and 100, if the number is 1 it will start garbage collecting. If your usercount is low you might want to reduce that value..
This method has worked pretty well for me (and you don't need CRON)
Evert
Whoever heard of someone looking at a webpage for 20 minutes?Originally Posted by siteguru
Location: Alicante (Spain)... Hot and Sunny...
Texas Holdem Poker Probability Calculator | DNS test
Avatars | English Spanish Translation | CAPTCHA with audio
Email | PHP scripts | Cruft free domain names | MD5 Cracker
I guess that was a more general system, for a management app i would want a longer timeout![]()
Bookmarks