Forum Moderators: coopster

Message Too Old, No Replies

Threaded Style Forum help needed

Taking Suggestions on how best to store and retrieve data from mysql DB

         

IamStang

11:55 pm on Nov 14, 2005 (gmt 0)

10+ Year Member



Hello again.

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

IamStang

4:32 am on Nov 15, 2005 (gmt 0)

10+ Year Member



Nevermind....lol

Found a basic tutorial that I can build off of.