well, I have zero experience doing something like that, but here's my 2 cents anyway ...
Do exactly what paul088 mentioned, however have 2 timestamp fields. One would contain the time of when they logged-on, the other would contain the time of their last refresh/page change. Just update the second timestamp field everytime they change pages on your site. That way you don't have to delete anyone from the table, instead you can return just the users that have refreshed/changed pages in the last ## minutes. If someone hasn't refreshed or clicked a link on your page in 20-25 minutes, chances are they are gone.
.. you could also create a userid field in that table, so you can update the info in the table the next time they come to the site, instead of creating redundent times for each user.