/**
  *	sendNewModeratedMsgNotice - contains the logic to send out email notifications to the forum admins when a new moderated message is posted
  *
  *	@return boolean success.
  */
 function sendNewModeratedMsgNotice()
 {
     $ids =& $this->Forum->getForumAdminIDs();
     //
     //	See if there is anyone to send messages to
     //
     if (!count($ids) > 0 && !$this->Forum->getSendAllPostsTo()) {
         return true;
     }
     $f =& $this->getForum();
     $g =& $f->getGroup();
     $body = "\nRead to this message and approve/reject it at: " . "\n" . util_make_url('/forum/admin/pending.php?action=view_pending&group_id=' . $g->getID() . "&forum_id=" . $f->getID()) . "\nBy: " . $this->getPosterRealName() . "\n\n";
     $text = $this->getBody();
     $sanitizer = new TextSanitizer();
     $text = $sanitizer->convertNeededTagsForEmail($text);
     $text = strip_tags($this->removebbcode(util_line_wrap($text)));
     $text = $sanitizer->convertExtendedCharsForEmail($text);
     $body .= $text . "\n\n______________________________________________________________________" . "\nYou are receiving this email because the forum you administrate has a new moderated message awaiting your approval.";
     //$extra_headers = 'Reply-to: '.$this->Forum->getUnixName().'@'.$GLOBALS['sys_default_domain'];
     $extra_headers = "Return-Path: <noreply@" . $GLOBALS['sys_default_domain'] . ">\n";
     $extra_headers .= "Errors-To: <noreply@" . $GLOBALS['sys_default_domain'] . ">\n";
     $extra_headers .= "Sender: <noreply@" . $GLOBALS['sys_default_domain'] . ">\n";
     $extra_headers .= "Reply-To: " . $this->Forum->getReturnEmailAddress() . "\n";
     $extra_headers .= "Precedence: Bulk\n" . "List-Id: " . $this->Forum->getName() . " <forum" . $this->Forum->getId() . "@" . $GLOBALS['sys_default_domain'] . ">\n" . "List-Help: " . util_make_url('/forum/forum.php?id=' . $this->Forum->getId()) . "\n" . "Message-Id: <forumpost" . $this->getId() . "@" . $GLOBALS['sys_default_domain'] . ">";
     $parentid = $this->getParentId();
     if (!empty($parentid)) {
         $extra_headers .= "\nIn-Reply-To: " . $this->Forum->getReturnEmailAddress() . "\n" . "References: <forumpost" . $this->getParentId() . "@" . $GLOBALS['sys_default_domain'] . ">";
     }
     $subject = "[" . $this->Forum->getUnixName() . "][" . $this->getID() . "] " . util_unconvert_htmlspecialchars($this->getSubject());
     if (count($ids) != 0) {
         $sql = "SELECT email FROM users WHERE status='A' AND user_id IN ('" . implode($ids, '\',\'') . "')";
         $bccres = db_query($sql);
     }
     ($BCC =& implode(util_result_column_to_array($bccres), ',')) . ',' . $this->Forum->getSendAllPostsTo();
     $User = user_get_object($this->getPosterID());
     //util_send_message('',$subject,$body,$User->getEmail(),$BCC,$this->getPosterRealName(),$extra_headers);
     util_send_message('', $subject, $body, "noreply@" . $GLOBALS['sys_default_domain'], $BCC, 'Forum', $extra_headers);
     //		util_handle_message(array_unique($ids),$subject,$body,$this->Forum->getSendAllPostsTo(),'','forumgateway@'.$GLOBALS[sys_default_domain]);
     return true;
 }