|
|
1.6.4: add_topic
Description
This functions adds a topic to the database.
Function call
add_topic ($tid, $username, $password, $ttitle, $text, $icon, $enable_smilies, $mail_on_reply);
Input
The function of the parameters is:
| Parameter | Description |
| $tid | The ID of the topic to add. |
| $username | The username of the user who has rights to edit the topic. |
| $password | The password belonging to the user. |
| $ttitle | The title of the topic |
| $text | The text of the first post in the topic. |
| $icon | the ID of the icon belonging to the first post. |
| $enable_smilies | "1" if smilies are enabled, "0" if not. |
| $mail_on_reply | "1" if mail on reply is enabled, "0" if not. |
|
Output
The output is the result of the add. Each resultvalue has the following description:
| Value | Description |
| 0 | No errors, topic succesfully added. |
| 1 | User not logged in. |
| 2 | No or invalid ttitle given. |
| 3 | No or invalid text given. |
| 4 | No sid given. |
| 5 | Invalid sid given. |
| 9 | Unknown database error. |
|
|