Forum Moderators: coopster
I have been working on a site for friends of mine, which some of you have already helped me out on with a security issue (thank you). NOW, I have been asked to add a basic MySql/php "threaded style" forum so that certain members can comunicate freely. EX:
1. Message 1 title
:::::::Reply one
::::::::::Reply to one
:::::::Reply two
2. Message 2 title
etc., etc,
I have never scripted something like this and havent a clue where to begin. Well, maybe a little bit of a clue. LOL.
I guess I would need to set up some type of "Parent/Child" id system. Maybe use an auto incrementing id for actual message IDs and a second field for inserting the reply message's "Parent"?
(mess_id)(mess_parent)(mess_time)(mess_body)
(figuring I would need a timestamp(mess_time) to order messages that have either no parent(main post) or multiple messages that have the same parent)
Using the above as an example, how would I call them to show them threaded? I guess this is what is giving me the most trouble. The call to the database to show them in the proper order.
Anyone with a size 12 care to give me a kick in the right direction?
Thanks for your time,
IamStang