hi all - we use a staffpage mod for vbadvanced on our 3.8.4 vb forum, and have done for some years, ive used the basic mod to create other similar pages - ie for tagged members and clans ect..
last night our hosting apparently did some kind of a server upgrade , since then everything still works except any pages using a module that uses on of these 3 php files..
php file example -
PHP Code:
<?php
//////////////////////////////////////////////////////////////////////////////////
// staffpage.php version 1.6
// A dynamic staffpage for vBadvanced CMPS
// Installation Instructions
//////////////////////////////////////////////////////////////////////////////////
// staffpage.php /////////////////////////////////////////////////////////////////
// 1.6 Added support for filesystem and database
// 1.5 Added support for vBulletin 3.5
// 1.4a Added display of staff without a profile pic
// 1.4 Added support for updated profile images
// 1.3 Added support for secondary usergroups
// 1.2 Added display of line breaks
// Seperated titles to allow for spaces
// Added links to member profiles from name and picture
// Fixed width display for non uniform profile pics.
// 1.1 Reverted to use all three usergroups.
// 1.0 Initial code
//////////////////////////////////////////////////////////////////////////////////
// ? 2005 Written by Alexander "Kesomir" Worton
// You are not permitted to remove the link to Online Gamers or distribute this code
// http://www.onlinegamers.org.uk <- UK based PC Gaming enthusiasts community
//////////////////////////////////////////////////////////////////////////////////
// Read the installation instructions. Support is only provided at Online Gamers
// enter the number of your biography field //////////////////////////////////////
$bionum = "5";
$picturewidth = "100";
///////////////////////// NO NEED TO EDIT BELOW THIS LINE ///////////////////////
$biofield = "field".$bionum;
// Grabbing that data
$result = $db->query_read("SELECT userfield.userid, user.userid, user.username, user.membergroupids, user.usergroupid, user.avatarrevision, user.profilepicrevision, customprofilepic.dateline, customprofilepic.filename, userfield.$biofield
FROM " . TABLE_PREFIX ."userfield AS userfield
INNER JOIN " . TABLE_PREFIX ."user AS user ON (userfield.userid=user.userid)
LEFT JOIN " . TABLE_PREFIX ."customprofilepic AS customprofilepic ON (customprofilepic.userid=user.userid)
WHERE FIND_IN_SET(5,user.membergroupids) OR FIND_IN_SET(6,user.membergroupids) OR FIND_IN_SET(67,user.membergroupids) OR FIND_IN_SET(9,user.membergroupids)OR FIND_IN_SET(7,user.membergroupids)OR FIND_IN_SET(54,user.membergroupids)
OR (user.usergroupid = 5) OR (user.usergroupid = 6) OR (user.usergroupid = 67) OR (user.usergroupid = 9)OR (user.usergroupid = 7)OR (user.usergroupid = 54)
ORDER BY userfield.userid ASC
");
//loop it baby yeah!
while($row = mysql_fetch_array($result))
{
$bio = stripslashes(nl2br($row[$biofield]));
$susername = $row['username'];
$susergroup = $row['usergroupid'];
if (in_array('9',explode(",", $row['membergroupids'])))
{
$susergroup = "9";
}
if (in_array('67',explode(",", $row['membergroupids'])))
{
$susergroup = "67";
}
if (in_array('54',explode(",", $row['membergroupids'])))
{
$susergroup = "54";
}
if (in_array('5',explode(",", $row['membergroupids'])))
{
$susergroup = "5";
}
if (in_array('6',explode(",", $row['membergroupids'])))
{
$susergroup = "6";
}
if (in_array('7',explode(",", $row['membergroupids'])))
{
$susergroup = "7";
}
switch ($susergroup)
{
case "7":
$staffrank = "VeteranModerator";
$staffname = "Veteran Moderator";
break;
case "6":
$staffrank = "Administrator";
$staffname = "Founder";
break;
case "54":
$staffrank = "Administrator";
$staffname = "Founder";
break;
case "9":
$staffrank = "ServerAdmin";
$staffname = "Server Admin";
break;
case "67":
$staffrank = "GServerAdmin";
$staffname = "Girly Server Admin";
break;
case "5":
$staffrank = "Moderator";
$staffname = "Moderator";
break;
}
// if ($row['userid'] != 1) uncomment these three lines to stop the default admin account from appearing. (Line 1)
// { //uncomment these three lines to stop the default admin account from appearing. (Line 2)
$$staffrank .= "<table class=\"tborder\" cellpadding=\"$stylevar[cellpadding]\" cellspacing=\"$stylevar[cellspacing]\" border=\"0\" width=\"100%\" align=\"center\">";
$$staffrank .= "<thead><tr align=\"left\" height=\"10\"><td class=\"tcat\">";
$$staffrank .= "<span class=\"smallfont\"><b>$vboptions[blockbullet] ".$staffname." <a href=\"$vboptions[bburl]/forum/member.php?u=".$row[userid]."\">".$susername."</a></b></td>";
$$staffrank .= "</tr></thead>";
$$staffrank .= "<tr class=\"alt2\">";
$$staffrank .= "<td class=\"alt1\" width=\"100%\">";
$$staffrank .= "<!-- avatar -->";
$$staffrank .= "<table align=\"left\" cellspacing=\"4\"><tr><td>";
$$staffrank .= "<a href=\"".$vbulletin->options[bburl]."/member.php?u=".$row[userid]."\">";
if ($vbulletin->options['usefileavatar'])
{
$$staffrank .= "<img src=\"".$vbulletin->options[bburl]."/customprofilepics/profilepic".$row[userid]."_".$row[profilepicrevision].".gif\" border=\"0\" width=\"$picturewidth\" /></a> </td></tr></table>";
}
else {
$$staffrank .= "<img src=\"".$vbulletin->options[bburl]."/image.php?u=".$row[userid]."&type=profile&dateline=".$row[dateline]."\" valign=\"top\" alt=\"".$row[username]."\" border=\"0\" width=\"$picturewidth\" /></a> </td></tr></table>";
}
$$staffrank .= "<!-- /avatar -->";
$$staffrank .= "<div align=\"left\">".$bio."</div>";
$$staffrank .= "</td>";
$$staffrank .= "</table> <br />";
// } //uncomment these three lines to stop the default admin account from appearing. (Line 3)
}
eval('$home[$mods[\'modid\']][\'content\'] = "' . fetch_template('adv_portal_staffmembers') . '";');
?>
nothing has changed with these files - but they just dont work anymore..
ive asked our hosting and they say it might be a php5 incompatability ?