I've written my own discussion software (it works quite nicely), but I have had a feature request from one of our users to mark discussions "since my last visit" as new. (Currently, we simply mark any discussion item updated in the last 24 hours as new.) So...
How do I calculate the date/time that a user "last visited"?
What's the typical way that forum software works out a "last visit" date/time?
We persist "views" of posts by the users. A view relates a post to a user and a time stamp. When a user loads a page, any posts displayed on that page are marked as viewed by that user, if they have not been viewed already. Then, new posts are simply those which have not been seen by the user yet.