For some reason, I can't get Rangersfan's code to work on my board. I followed the instructions exactly and didn't change any of the code except for the image names and image sizes. Has anyone else had any problems getting this working? or is there something I have to do after editing showthread.php? Here's what my code looks like after I add the hack:
Code:
$userinfo=$DB_site->query_first("SELECT usergroupid,userid,email,username,usertitle,signature,showemail,homepage,icq,aim,yahoo,joindate,posts FROM user WHERE userid=$userid");
$username=htmlspecialchars($userinfo[username]);
$searchuser=urlencode($userinfo[username]);
$usertitle=$userinfo[usertitle];
$userjoindate=date($registereddateformat,$userinfo[joindate]+(($timeoffset+$bbtimezoneoffset)*3600));
$userpostcount=$userinfo[posts];
// --- Stars Hack by rangersfan
$stars = "";
$s_usergroup = $userinfo[usergroupid];
$moderator=$DB_site->query_first("SELECT usergroupid FROM forumpermission WHERE usergroupid = $s_usergroup AND canadminedit=1");
if (($moderator[usergroupid] == $s_usergroup)||($s_usergroup==6))
{
$starsgif = "<img src=\"images/yellowstar.gif\" border=\"0\" width=\"10\" height=\"9\">";
}
else
{
$starsgif = "<img src=\"images/bluestar.gif\" border=\"0\" width=\"10\" height=\"9\">";
}
if ($userpostcount > 1999)
{ $stars .= $starsgif . $starsgif . $starsgif . $starsgif . $starsgif; }
elseif ($userpostcount > 999)
{ $stars .= $starsgif . $starsgif . $starsgif . $starsgif; }
elseif ($userpostcount > 399)
{ $stars .= $starsgif . $starsgif . $starsgif; }
elseif ($userpostcount > 99)
{ $stars .= $starsgif . $starsgif; }
elseif ($userpostcount > 19)
{ $stars .= $starsgif; }
if ($stars == "")
{
$stars .= "<br>";
}
else
{
$stars .= "<br><br>";
}
// - Stars Hack
-Tom