Also ich weiß nicht ob es dir helfen kann, aber so habe ich es bei mir:
function text_replace($text) {
$text = str_replace("
", "", $text); $text = str_replace("", "", $text);
$text = str_replace("[scroll]", "", $text);
$text = str_replace("[/scroll]", "", $text);
$text = str_replace("[fade]", "", $text);
$text = str_replace("[/fade]", "", $text);
$text = str_replace("[glow]", "", $text);
$text = str_replace("[/glow]", "", $text);
$text = str_replace("[shadow]", "", $text);
$text = str_replace("[/shadow]", "", $text);
$text = str_replace("[highlight]", "", $text);
$text = str_replace("[/highlight]", "", $text);
$text = str_replace("[li]", "
", $text); $text = str_replace("[/li]", "", $text);
$text = str_replace("[br]", "
", $text);
$text = str_replace("[/br]", "
", $text);
$text = str_replace("", "", $text);
$text = str_replace("", "", $text);
$text = str_replace("
", "", $text); $text = str_replace("", "", $text);
$text = eregi_replace("\\[url\\]www.([^\\[]*)\\[/url\\]","
\\1",$text);
$text = eregi_replace("\\[url\\]([^\\[]*)\\[/url\\]","
\\1",$text);
$text = eregi_replace("\\[url=\"","[url=\"",$text);
$text = eregi_replace("\\"\\]","\"]",$text);
$text = eregi_replace("\\[url=\"([^\\[]*)\"\\]([^\\[]*)\\[\\/url\\]", "
\\2", $text);
$text = eregi_replace("\\[url=([^\\[]*)\\]([^\\[]*)\\[\\/url\\]", "
\\2", $text);
$text = eregi_replace("\\[email\\]([^\\[]*)\\[/email\\]", "
\\1", $text);
$text = eregi_replace("\\[email=([^\\[]*)\\]([^\\[]*)\\[/email\\]", "
\\2", $text);
$text = str_replace("[center]", "", $text);
$text = str_replace("[/center]", "", $text);
$text = str_replace("[*]", "
", $text); $text = str_replace("
$text = str_replace("", "", $text);
return $text;
}