Re: Read Messages on Forums
Quote:
Originally posted by richy
[B]I have a forum on my site and want to add the feature that each user can see which threads they have viewed and which they haven't.[B]
By makeing a few asumptions you should be able to get around alsorts of problems and only add one perminant field to the user table.
Use this field to record the exact time and date "Now()" that they last visited the site. Then mark each post that is new since then. If you use the session variable to store the unique ID of these tables before updateing [Date Of Last Visit] for this visit with the new time and date then you can remove viewed IDs from the list as they get viewed.
If that sounds like too much you could just do:
Code:
<p>There are :<%=Sum(Records > LastVisit)%>
new posts since your last visit</p>