I've got a sticky little problem in my PHP programming.
I'm writing a commenting system on an article CMS. It uses
PHP and MySQL. Articles are stored in a database. Comments
are also stored with an ID relationship that 'points' at a given
article that has the comments on it.
Each of the comments on a given article, has to have a [NEW] tag next to it
when the logged-in visitor looks at that page again, and hasn't seen a recent
comment on that particluar article. I'm trying to figure out how to do this.
I thought it was a question of comparing the date of the last time the article
was read, to the date of creation of the comment being displayed. So how to
save the date of the last time the article was read? By a logged-in visitor.
That implies cookies.
I mean, it has to imply cookies because we're talkling about a individual visitor.
If we store anything in the database itself, that would apply to all visitors.
But a cookie that stores the time for each and every article the visitor may have read?
What if there are hundreds of articles being read?
Wouldn't the cookies hit their maximum limit pretty quick?
I gotta say -- I can't quite figure out how to do this.
Any suggestions would be appreciated.
Thanks
....Vidya
www.webwisesage.com