<? require "include/functions.php";
global $pic_base_url;
dbconn();
stdhead("Staff");
begin_main_frame();
// Display Staff List to all users
begin_frame("Staff");
// Get current datetime
$dt = get_date_time(gmtime() - 180);
// Search User Database for Moderators and above and display in alphabetical order
$res = mysql_query("SELECT * FROM users WHERE class>=".UC_MODERATOR.
" AND status='confirmed' ORDER BY username") or sqlerr();
$num = mysql_num_rows($res);
while ($arr = mysql_fetch_assoc($res))
{
$staff_table[$arr['class']]=$staff_table[$arr['class']].
"<td class=embedded><img src=$pic_base_url/button_o".($arr[last_access]>$dt?"n":"ff")."line.gif></td>".
"<td class=embedded><a class=altlink href=userdetails.php?id=$arr[id]>$arr[username]</a></td>".
"<td class=embedded><a href=sendmessage.php?receiver=$arr[id]>".
"<img src=$pic_base_url/button_pm.gif border=0></a></td>".
"<td class=embedded><a href=email-gateway?id=$arr[id]>".
"<img src=$pic_base_url/button_mail.gif border=0 alt=$arr[email]></a></td>";
// Show 3 staff per row, separated by an empty column
++ $col[$arr['class']];
if ($col[$arr['class']]<=3)
$staff_table[$arr['class']]=$staff_table[$arr['class']]."<td class=embedded> </td>";
else
{
$staff_table[$arr['class']]=$staff_table[$arr['class']]."</tr><tr height=15>";
$col[$arr['class']]=1;
}
}
?>
All software support questions and those already answered in the <a href=faq.php><b>FAQ</b></a> will be ignored.<br>
<br>
<table width=725 cellspacing=0 align=center>
<tr>
<td class=embedded colspan=14><b>SysOp</b></td>
</tr>
<tr>
<td class=embedded colspan=14><hr color="#4040c0" size=1></td>
</tr>
<tr height=15>
<?=$staff_table[UC_SYSOP]?>
</tr>
<tr>
<td class=embedded colspan=14> </td>
</tr>
<tr>
<td class=embedded colspan=14><b>Administrators</b></td>
</tr>
<tr>
<td class=embedded colspan=14><hr color="#4040c0" size=1></td>
</tr>
<tr height=15>
<?=$staff_table[UC_ADMINISTRATOR]?>
</tr>
<tr>
<td class=embedded colspan=14> </td>
</tr>
<tr>
<td class=embedded colspan=14><b>Moderators</b></td>
</tr>
<tr>
<td class=embedded colspan=14><hr color="#4040c0" size=1></td>
</tr>
<tr height=15>
<?=$staff_table[UC_MODERATOR]?>
</tr>
<tr>
<!-- Define table column widths -->
<td class=embedded width="20"></td>
<td class=embedded width="100"></td>
<td class=embedded width="25"></td>
<td class=embedded width="35"></td>
<td class=embedded width="90"></td>
<td class=embedded width="20"></td>
<td class=embedded width="100"></td>
<td class=embedded width="25"></td>
<td class=embedded width="35"></td>
<td class=embedded width="90"></td>
<td class=embedded width="20"></td>
<td class=embedded width="100"></td>
<td class=embedded width="25"></td>
<td class=embedded width="35"></td>
</tr>
</table>
<? end_frame();
/* Display Site Owner Tools if user is Sysop */
if (get_user_class() >= UC_SYSOP)
{
begin_frame("Site Owner Tools<font color=#FF0000> - Viewable by SysOp only.</font>"); ?>
<form method=get action=PhpMyAdmin/index.php><input type=submit value="PHPMyAdmin" style='height: 20px; width: 100px'>
   Enter PHPMyAdmin
</form>
<form method=get action=unco.php>
<input name="submit" type=submit style='height: 20px; width: 100px' value="Unconfirmes">
   Delete Unconfirmes Users
</form>
<form method=get action=staffmess.php>
<input name="submit2" type=submit style='height: 20px; width: 100px' value="Mass mesaje">
   Mass Mesaje
</form>
<p>
<? end_frame();
}
/* Display Administrator Tools if user is Administrator or above */
if (get_user_class() >= UC_ADMINISTRATOR)
{
begin_frame("Administrators Tools<font color=#FF0000> - Viewable by Administrators & above only.</font>"); ?>
</p>
<form method=get action=bans.php><input type=submit value="Ban IP" style='height: 20px; width: 100px'>   Add an IP address/range to the ban list.</form>
<form method=get action=makepoll.php><input type=submit value="Create Poll" style='height: 20px; width: 100px'>   Create a new poll.</form>
<? end_frame();
}
/* Display Moderator Tools if user is Moderator or above */
if (get_user_class() >= UC_MODERATOR)
{
begin_frame("Moderators Tools<font color=#FF0000> - Viewable by Moderators & above only.</font>"); ?>
<form method=get action=users.php><input type=submit value="User List" style='height: 20px; width: 100px'>   Search/browse/edit users.</form>
<form method=get action=recover.php><input type=submit value="Recover Account" style='height: 20px; width: 100px'>   Recover lost account details.</form>
<form method=get action=delacct.php><input type=submit value="Delete Account" style='height: 20px; width: 100px'>   Delete an account.</form>
<form method=get action=testip.php><input type=submit value="Test IP" style='height: 20px; width: 100px'>   Check if an IP address is banned.</form>
<form method=get action=warned.php><input type=submit value="Warned Users" style='height: 20px; width: 100px'>   View users Warned.</form>
<form method=get action=viewrequests.php><input type=submit value="Requests" style='height: 20px; width: 100px'>   View users Request.</form>
<? end_frame();
}
end_main_frame();
stdfoot();
?>