easy62120 |
15th May 2012 13:22 |
text shoutbox
I want to shout from the text color by rank
Here is my code:
PHP Code:
if ($arr2["usergroup"] == "11") $arr1= "[color=#ff5151]"; if ($arr2["usergroup"] == "10") $arr1= "[color=#2587A7]"; if ($arr2["usergroup"] == "8") $arr1= "[color=#CC0000]"; if ($arr2["usergroup"] == "7") $arr1= "[color=#2587A7]"; $text = "[color=#CC0000]".$row[text]."[/color]"; if ($arr2["usergroup"] == "6") $arr1= "[color=#CC6600]"; $text = "[color=#CC6600]".$row[text]."[/color]"; if ($arr2["usergroup"] == "5") $arr1= "[color=#0749f3]"; $text = "[color=#0749f3]".$row[text]."[/color]"; if ($arr2["usergroup"] == "4") $arr1= "[color=#B400FF]"; $text = "[color=#B400FF]".$row[text]."[/color]"; if ($arr2["usergroup"] == "3") $arr1= "[color=#05da37]"; $text = "[color=#05da37]".$row[text]."[/color]"; if ($arr2["usergroup"] == "2") $arr1= "[color=#f9a200]"; $text = "[color=#f9a200]".$row[text]."[/color]"; if ($arr2["usergroup"] == "1") $arr1= "[color=#FFFF66]"; $text = "[color=#FFFF66]".$row[text]."[/color]";
and I replaced this:
PHP Code:
$shout_content = format_comment ($shout_row['content'], true );
By:
PHP Code:
$shout_text = format_comment($text);
and set below this line as follows:
PHP Code:
$str .= '' . '<span class=\'shoutbox\'>' . $avatars . ' ' . $date . ' ' . $mod . ' ' . $onoffpic . ' ' . $UserGender . ' ' . $country . ' ' . $Userpm . ' ' . $valasz . ' ' . $shouter_name . ' - ' . $shout_text . '</span>';
But only BBCode appear and not the text
|