Hey,
I'm currently building my own forum, and I'm stuck with one thing:
Most forums have an "option" that shows an image in front of the topic.
If it's an empty box, you have already read it, but if it's closed (just to give an example) it's not read yet.
This is extra handy for the one reading the forum, since he'll know in what topic there have been new replies.
I tried to make something similar, but I'm stuck now.
First of all, I made a cookie that set the time of the last visit (so if you got to the forum at 12pm, a cookie will be set at 12pm with ofcourse the date in it as well).
Then in the topic table, I also made a lastentry box, that get's updated whenever someone adds a post or something similar.
The only problem is, if I set the cookie at the beginning of the forumindex, you will NOT see all the new messages from your latest visit, since the lastvisit will be changed to the time it is now.
If I set the cookie at the very end of the forumindex, you WILL see the latest results, but if you check a topic, and then go back, you WON'T see any more new topics, since the cookie has already been set.
Is there a way to set a cookie AFTER the person closes the window or is there another, better way to do this (maybe having a cookie set for each topic, but that would be a very long one 🙂)??
Kind regards,
Menno van Dijk