-1) { $end = strpos($message, ">", $start); if($end) { $length = $end - $start + 1; $tagallowed = 0; for($i = 0; $i < sizeof($board_config['allow_html_tags']); $i++) { $match_tag = trim($board_config['allow_html_tags'][$i]); list($match_tag_split) = explode(" ", $match_tag); if( preg_match("/^((\/" . $match_tag_split . ")|(" . $match_tag . "))[ \=]+/i", trim(substr($message, $start + 1, $length - 2)) . " ") ) { $tagallowed = 1; } } if($length && !$tagallowed) { $message = str_replace(substr($message, $start, $length), htmlspecialchars(substr($message, $start, $length)), $message); } } $start = -1; } } } if($bbcode_on) { $message = bbencode_first_pass($message, $bbcode_uid); } $message = addslashes($message); return($message); } ?>