That makes a lot of sense, I think it puts me on the right track.
On Jan 27, 7:47 pm, cricket zijn.digi...@gmail.com wrote:
and removing the viewed rows in the db when a comment is added
I don't understand what you mean by that. If it's what I think then
I'd guess it would require a lot of
Its a good idea, but i want to be able to see when a user has viewed a
comment, and then act upon that at the end of the day. The solution
i'm going with is tracking the post views, as opposed to the comment
views, and removing the viewed rows in the db when a comment is added.
any thought?
On
and removing the viewed rows in the db when a comment is added
I don't understand what you mean by that. If it's what I think then
I'd guess it would require a lot of writes to the DB.
I did put something together last night. It's a bit rough around the
edges but it's a start. It involves code
Hi all, I am trying to do something, and cant work out where to start.
I have the blog app running, and have the comments paginated under the
post. I have auth working, and would like to track when a user views a
comment (Think marking as read)
I have a db table viewedcomments, with the fields
Can I understand that you are only showing one comment at a time, even
together with a post?
In case that is correct, then one solution is to specific read all the
ViewedComment records for the post and the user, and ask in the view,
is the current comment in the ViewedComment array of records.
I think the most efficient thing to do would be to update a timestamp
whenever a user views a post. Maybe have a posts_users table with an
extra column and use contain to include it in your results. Update the
column in afterFind() maybe?
Then, in the view, compare the original ts that you got