This function requires certain parameters
$use_current_db : using the data basis in process or not, provided by the constant md_one_database
$current_forum : Data basis of the forum in process, provided by the variable $md_db_extension
$cat : ID of the cat, provided by the variable $md_cat_id if this has to be the category in process
$topic_id : ID of the topic, provided by $md_topic_id if this has to be the topic in process
$in_trash : Boolean to know if the topic is in the trash or, for a topic not in the trash put 0 in the parameter.
$dbhr and $dbhw : Links to the databases connexion(s), initialized by $dbhr and $dbhw
$dbhr et $dbhw : Links to the databases, provided by $dbhr and $dbhw
$forum_id : ID of the forum provided by $md_forum_id, this is an optional function; if not provided, it will return the total number of registered members on the whole server.
$current_forum : name of the forum in process, initialized by the variable $md_db_extension
$use_current_db : using the data basis in process, provided by the constant md_one_database
$topic_id : ID of the topic to be notified, if this is the topic in process, it is provided by $md_topic_id
$cat : ID of the category where is located the topic to be notified, if this is the category in process, it is provided by $md_cat_id
$idu : ID of the user who will receive the notification, if this is the user in process, it is provided by $md_user_id
$dbhr and $dbhw : connexion links to the mysql in process, provided by $dbhr and $dbhw
If the action has been successfully performed, it will return the value “true”. Otherwise, it will return the value “false”
$use_current_db : Asks the function to use the database in process or another particular databasis. Can be provided by the contant md_one_database
$current_forum : Extension name of the forum data basis in process, provided by the variable $md_db_extension // db name of the forum
$id_forum : ID of the forum where the topic should be posted, provided by the variable $md_forum_id of the forum in process
$cat : ID of the category where the topic should be posted, initialized by the variable $md_cat_id if it is the category in process.
$subcat : ID of the sub category where the topic should be posted, initialized by the variable $md_subcat_id if it is the sub category in process.
$sticky : indicates if this topic should be glued at the top of the topic list, put 1 to make it a sticky
$subject : title of the new topic, must be protected by md_mysqlw_real_escape_string
$content : content of the first message, must be protected by md_mysqlw_real_escape_string
$poll : enables you to add a poll in the topic. With a PHP array,
0 : title of the poll
1-10 : poll choices
99 : maximum number of votes
$MsgIcon : topic tone emoticon image
$user_id : ID of the user who will be recorded as the creator of the topic, $md_user_id if this is the user in process.
$pseudo : Pseudo of the user who will be recorded as the creator of the topic, must be protected by md_mysqlw_real_escape_string, can therefore be retrieved by md_mysqlw_real_escape_string($md_user,$dbhw); if this is the user in process.
$date : date of the topic creation in the form YYYY-MM-JJ HH:mm:ss
$signature : To activate or deactivate the user’ signature
$toread : Table which can contain up to 5 keys for the topic IDs
$remote : IP address behind the proxy if this is a transparent proxy, initialized by the variable $md_user_proxy_ip if this is the user in process.
$current_ip : IP of the user, initialized by the variable $md_user_ip if this is the user in process
$topicParPage : number of topics per page on the default topic list, initialized by the variable $md_topic_per_page.
$dbhr and $dbhw : Connexion links to the data bases.
The parameters below are optional. If you do not precise their functions, their default value will be used
$stickyallowed : 0 by default, put 1 to allow sticky topic creations
$apriori : 0 by default, put 1 if you want to create a topic with a priori moderation, which means that this topic will not be displayed on the forum before it has been validated in the A Priori moderation interface
$expire : Array PHP, by default (0,0,0,0,0). Allows you to precise an expiration date for a poll
This function will return a PHP table that contains 2 values, the ID of the newly-created topic and the ID of the first message of this topic
$use_current_db : Using the data basis in process, provided by the constant md_one_database
$current_forum : Name of the forum in process, provided by the variable $md_db_extention
$idsite : ID of the forum in process, initialized by the variable $md_forum_id
$cat : ID of the category where the topic should be created. Initialized by the variable md_cat_id if this is the category in process
$topic_id : ID of the topic where the repy should be posted. Initialized by the variable md_topic_id if the reply should be added to the topic in process.
MsgIcon : Mood icon image for the reply.
$safe_content : Content of the repy, must be verified by md_mysqlw_real_escape_string before calling the function. Otherwise you may be subjected to a mysql Injection failure.
$safe_pseudo : Pseudo of the reply poster, must be verified by md_mysqlw_real_escape_string before calling the function. Otherwise you may be subjected to a mysql Injection failure.
$id : ID of the user who posted the reply, initialized by the variable $md_user_id if this is the user in process.
$signature : to activate or deactivate the signature at the end of the message
$remote : IP address behind the proxy if this is a transparent proxy, initialized by the variable $md_user_proxy_ip if this is the user in process.
$current_ip : IP of the user, initialized by the variable $md_user_ip if this is the user in process
$apriori : Defines if the message should be directly displayed on the forum or if should first be validated in the a priori moderation interface.
$dbhr and $dbhw : Links to the databases connexion(s).
$subcat : Sub category of the topic where the message should be posted, useful if you want to retain information like the last poster of a particular category. This is especially the case if you have a category which is an “alias” to a sub category
This function returns the ID of the posted message.