How to create a new thread?

Started by CND Bacon, May 14, 2007, 02:54:09 PM

Previous topic - Next topic

CND Bacon

Hi Guys,

I have a clan gaming site and i use SMF (great forum).

Anyways - I created a form to accept challenges - and I would like to take the data from that same form and create a new thread within a specific board (id_board  25) and from a specific member (ID_MEMBER 2) that already exists.

1.  What are the minimum fields I need to supply?
2.  Which table do I post to 1st (topics or messages)?
3.  How do I get the last previous auto_increment ID?

Any and all help would be greatly appreciated.




smf_topics

id_topic ?auto
isSticky 0
id_board 25
ID_FIRST_MSG   (how do I get the message ID??)
ID_MEMBER_STARTED 2
ID_POLL 0
locked 0

--------------------

smf_messages

ID_MSG
ID_TOPIC  (how do I get the topic ID??)
ID_BOARD 25
posterTime  (do I use date('U')? )
ID_MEMBER 2
subject   XYZ Subject
posterName   siteAdmin
posterEmail   [email protected]
posterIP  XXX.XXX.XXX.XXX
smileysEnabled 1
body blah blah blah
icon thumbup

Advertisement: