[Pugged] Tracking Read Topics/Messages, and the "unread" flag.

Chris Hettinger ciapug@ciapug.org
Fri, 06 Sep 2002 14:13:53 -0500


So am I correctly hearing you, I have basically two choices:

1. Based on a date comparison only:
I store a time/date stamp in the members profile, upon a visit I compare =
the forums/topics most recent activity to the stamp stored for the user.

Pros: Likely the easiest way
Cons: Can't flag a topic for forum individually.

OR

2. I maintain a table containing a record for each user's read topics:
Like Tim's table diagram. In a table I store the id for every topic the =
user has read.

Pro: Could individually track a topic
Cons: Phew, logic. I would have to not only maintain the topic id, but =
that topic recent activity (last post stamp) to handle each time he views =
that topics, so that I don't have to also track each reply to a specific =
topic.... *head explodes*

... Sigh.

Chris Van Cleve:
I think #2. Once the user visits a the forums index page (Forum listing) I =
grab the last visited date, assign it to a variable then update that field =
in the members profile with the current time/date. This assigned variable =
is then used as the comparison for each forum and topic. I think the key =
should be that I only do that last visit update one time. Which I think I =
am doing, correctly. hmmm.

Tim:
You mentioned Phorum, how would their process mostly like compare to that =
of phpBB forums, or Invision Boards (another php based forum app) ... I =
have the phpBB source files, and looked through them but they are pretty =
cryptic to me still, so tearing them apart for logic is a hunting trip. I =
finally found a db table list and saw one name topic_watch which could be =
the table they use, similar to option 2 ...=20

hmmm.

-ch