0

Hi, I'm building a site where users can connect with each other. I'm trying to let users post comments like one would on Twitter or Facebook. Currently, I have it so the user has to update there comments but I would rather them post new ones. Basically, how is this done. Any keywords would be helpful, I'm just not sure where to start. Thanks!

4
Contributors
4
Replies
5
Views
6 Years
Discussion Span
Last Post by phpDave
1

like one would on Twitter or Facebook

different concepts different specs and even inside them are different logic in each service. First of all you must write down what you are doing in words first if you can’t directly in UML. Then you must set a plan of how to do it, and architecture to achieve it.

1

You need to post your DB structure. You have a choice of whether to make every post a new post (Twitter) or whether to use 'threads' (Facebook), where a first post on a new topic is the 'parent' and replies to that post are its children. Both systems are easy to implement.

You could have something like:

post_id | poster_id | title | body | timestamp | status | parent_id

So, if the parent id is not 0, the post has to be a child of that parent. If 0, the post is a parent. Anyway, quite a few ways you could go with this.

Edited by diafol: n/a

Votes + Comments
Good detailed answers
0

Thanks for responses. I have to think about structure more but answers helpful. I'm going to mark as solved for now but would like to ask more about this in future.

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.