while ($row = mysql_fetch_array($results))
{
$nick = $row["nick"];
$url = $row["url"];
$message = $row["message"];
$datetime = $row["datetime"];
/* Add Emoticons to the user's message */
if ($emoticon=="1" or $emoticon=="y")
$outcode = ti_code($message);
$usrmsg = "$outcode";
if ($url=="" or $url=="http://")
$nick = "<br><B>$nick";
else
$nick = "<br><B><a href=\"$url\" target=\"_blank\">$nick</a>";
if ($timestamping == 1)
echo " $nick ($datetime)$spacer</B> $usrmsg<BR>\n";
else
echo " $nick$spacer</B> $usrmsg<BR>\n";
}
mysql_close($connection);
That's how it get's displayed.
I'm trying to get PHP to read the information (text) contained in $message, then see if the $message contents have a /me to start with, in IRC scripts, it makes the usernames like...
***Name is useing /me
with a different font color, i'm trying to get it to read $message, if it includes /me, then to alter the username and message so that insted of it doing:
echo " $nick$spacer</B> $usrmsg<BR>\n";
I want it to do this insted:
echo " <font color=FFFFFF>***$nick$spacer</B> $usrmsg *</font><BR>\n";
hope that explains it better
-ag
***edit:
Oh yea, a tagboard is a small chat type thing that can be put on the side of a site so user's can chat back and forth while browseing it.
Sort of a Mini Chat, but without the big link and window.
***edit2:
I checked out the link coditoergosum posted,
i'm pretty sure
ereg ("abc", $string);
/ Returns true if"abc"
is found anywhere in $string. /
is what i'm looking for, however, I don't know how to use it or where it would go in the code. or how it's used.