Quote:
Originally Posted by buro9
Look... if you haven't seen the bug, or experienced it... cool
But if you've seen it, and it nags you... then a workaround is above.
You don't have to use it.
|
Erwin! I've got it!
Could you update your hack?
Code:
// HACK : START : ME
global $post;
if ('' == $post[username]) {
global $reputation;
if ('' == $reputation[username]) {
global $pm;
if ('' == $pm[fromusername]) {
$meUsername = $bbuserinfo[username];
} else {
$meUsername = $pm[fromusername];
}
} else {
$meUsername = $reputation[username];
}
} else {
$meUsername = $post[username];
}
$bbcode = preg_replace('#^/me (.*)$#im', "<span class=\"postAction\">* $meUsername \\1 *</span>", $bbcode);
// HACK : END : ME
Note I've changed one thing regards the formatting that you might not want to change... I use a stylesheet for it so that I can use different colours according to style in use.
But it's the nested if's that is important... solves /me for PM's and reputation bits