if (!empty($topic_id)) { $forumpost->setTopicId($topic_id); $isreply = 1; } $forumpost->setIp($HTTP_SERVER_VARS['REMOTE_ADDR']); $forumpost->setUid($uid); } $subject = xoops_trim($HTTP_POST_VARS['subject']); $subject = $subject == '' ? _NOTITLE : $subject; $forumpost->setSubject($subject); $forumpost->setText($HTTP_POST_VARS['message']); $forumpost->setNohtml($HTTP_POST_VARS['nohtml']); $forumpost->setNosmiley($HTTP_POST_VARS['nosmiley']); $forumpost->setIcon($HTTP_POST_VARS['icon']); $forumpost->setAttachsig($HTTP_POST_VARS['attachsig']); if (!($postid = $forumpost->store())) { include_once XOOPS_ROOT_PATH . '/header.php'; xoops_error('Could not insert forum post'); include_once XOOPS_ROOT_PATH . '/footer.php'; exit; } if (is_object($xoopsUser) && !empty($isnew)) { $xoopsUser->incrementPost(); } // RMV-NOTIFY // Define tags for notification message $tags = array(); $tags['THREAD_NAME'] = $HTTP_POST_VARS['subject']; $tags['THREAD_URL'] = XOOPS_URL . '/modules/' . $xoopsModule->dirname() . '/viewtopic.php?forum=' . $forum . '&post_id=' . $postid . '&topic_id=' . $forumpost->topic(); $tags['POST_URL'] = $tags['THREAD_URL'] . '#forumpost' . $postid; include_once 'include/notification.inc.php';