// IMPORTANT: UNIQUE_PLUGIN_NAME MUST BE 10 OR LESS CHARACTERS BECAUSE THE MYSQL COLUMN IS VARCHAR(10) require_once(e_HANDLER."comment_class.php"); $cobj = new comment; $comment_item_id = intval(e_QUERY); if(isset($_POST['submit']) && $_POST['comment']) { $cobj -> enter_comment($_POST['author_name'], $_POST['comment'], "UNIQUE_PLUGIN_NAME", $comment_item_id); } $qry = " SELECT c.*, u.*, ue.* FROM #comments AS c LEFT JOIN #user AS u ON c.comment_author = u.user_id LEFT JOIN #user_extended AS ue ON c.comment_author = ue.user_extended_id WHERE comment_item_id='$comment_item_id' AND comment_type='UNIQUE_PLUGIN_NAME' ORDER BY comment_datestamp "; if ($comment_total = $sql->db_Select_gen($qry)) { unset($text); while($row = $sql -> db_Fetch()) { $text .= $cobj -> render_comment($row); } $ns -> tablerender("Comments", $text); } $cobj -> form_comment();