Gazelle/sections/staff/index.php

146 lines
4.0 KiB
PHP
Raw Normal View History

2011-03-28 14:21:28 +00:00
<?
enforce_login();
2013-02-13 08:00:35 +00:00
View::show_header('Staff', 'jquery');
2011-03-28 14:21:28 +00:00
include(SERVER_ROOT.'/sections/staff/functions.php');
2013-02-13 08:00:35 +00:00
$SupportStaff = get_support();
2011-03-28 14:21:28 +00:00
list($FrontLineSupport, $ForumStaff, $Staff) = $SupportStaff;
2011-03-28 14:21:28 +00:00
?>
<div class="thin">
2012-08-19 08:00:19 +00:00
<div class="header">
<h2><?=SITE_NAME?> Staff</h2>
</div>
2013-04-13 08:00:19 +00:00
<div class="box pad" style="padding: 0px 10px 10px 10px;">
<br />
2011-03-28 14:21:28 +00:00
<h3>Contact Staff</h3>
<div id="below_box">
<p>If you are looking for help with a general question, we appreciate it if you would only message through the staff inbox, where we can all help you.</p>
2012-09-09 08:00:26 +00:00
<p>You can do that by <strong><a href="#" onclick="$('#compose').toggle();">sending a message to the Staff Inbox</a></strong>.</p>
2011-03-28 14:21:28 +00:00
</div>
2013-02-13 08:00:35 +00:00
<? View::parse('generic/reply/staffpm.php', array('Hidden' => true)); ?>
<br />
2011-03-28 14:21:28 +00:00
<h3>First-line Support</h3>
2013-02-07 08:00:47 +00:00
<p><strong>These users are not official staff members</strong> - they're users who have volunteered their time to help people in need. Please treat them with respect and read <a href="wiki.php?action=article&amp;id=260">this</a> before contacting them.</p>
2011-03-28 14:21:28 +00:00
<table class="staff" width="100%">
<tr class="colhead">
2013-04-13 08:00:19 +00:00
<td style="width: 130px;">Username</td>
<td style="width: 130px;">Last seen</td>
2011-03-28 14:21:28 +00:00
<td><strong>Support for</strong></td>
</tr>
<?
$Row = 'a';
2013-04-13 08:00:19 +00:00
foreach ($FrontLineSupport as $Support) {
2011-03-28 14:21:28 +00:00
list($ID, $Class, $Username, $Paranoia, $LastAccess, $SupportFor) = $Support;
$Row = ($Row == 'a') ? 'b' : 'a';
?>
<tr class="row<?=$Row?>">
<td class="nobr">
2013-04-13 08:00:19 +00:00
<?=Users::format_username($ID, false, false, false) ?>
2011-03-28 14:21:28 +00:00
</td>
<td class="nobr">
2013-04-13 08:00:19 +00:00
<? if (check_paranoia('lastseen', $Paranoia, $Class)) {
echo time_diff($LastAccess);
} else {
echo 'Hidden by user';
}
?>
2011-03-28 14:21:28 +00:00
</td>
<td class="nobr">
<?=$SupportFor?>
</td>
</tr>
<? } ?>
</table>
</div>
2013-04-13 08:00:19 +00:00
<div class="box pad" style="padding: 0px 10px 10px 10px;">
2012-09-24 08:00:33 +00:00
<br />
<h3>Forum Moderators</h3>
2013-02-07 08:00:47 +00:00
<p>Forum Moderators are users who have been promoted to help moderate the forums. They can only help with forum-oriented questions.</p>
<table class="staff" width="100%">
<tr class="colhead">
2013-04-13 08:00:19 +00:00
<td style="width: 130px;">Username</td>
<td style="width: 130px;">Last seen</td>
<td><strong>Remark</strong></td>
</tr>
<?
$Row = 'a';
2013-04-13 08:00:19 +00:00
foreach ($ForumStaff as $Support) {
list($ID, $Class, $Username, $Paranoia, $LastAccess, $SupportFor) = $Support;
$Row = ($Row == 'a') ? 'b' : 'a';
?>
<tr class="row<?=$Row?>">
<td class="nobr">
2013-04-13 08:00:19 +00:00
<?=Users::format_username($ID, false, false, false) ?>
</td>
<td class="nobr">
2013-04-13 08:00:19 +00:00
<? if (check_paranoia('lastseen', $Paranoia, $Class)) {
echo time_diff($LastAccess);
} else {
echo 'Hidden by user';
}
?>
</td>
<td class="nobr">
<?=$SupportFor?>
</td>
</tr>
2011-03-28 14:21:28 +00:00
<? } ?>
</table>
</div>
<br />
2013-04-13 08:00:19 +00:00
<div class="box pad" style="padding: 0px 10px 10px 10px;">
2011-03-28 14:21:28 +00:00
<?
$CurClass = 0;
$CloseTable = false;
foreach ($Staff as $StaffMember) {
2011-03-28 14:21:28 +00:00
list($ID, $Class, $ClassName, $Username, $Paranoia, $LastAccess, $Remark) = $StaffMember;
2013-04-13 08:00:19 +00:00
if ($Class != $CurClass) { // Start new class of staff members
2011-03-28 14:21:28 +00:00
$Row = 'a';
2013-04-13 08:00:19 +00:00
if ($CloseTable) {
2011-03-28 14:21:28 +00:00
$CloseTable = false;
2012-11-18 08:00:19 +00:00
echo "\t</table><br />";
2011-03-28 14:21:28 +00:00
}
$CurClass = $Class;
$CloseTable = true;
2012-11-18 08:00:19 +00:00
echo '<h3>'.$ClassName.'s</h3>';
2011-03-28 14:21:28 +00:00
?>
<table class="staff" width="100%">
<tr class="colhead">
2013-04-13 08:00:19 +00:00
<td style="width: 130px;">Username</td>
<td style="width: 130px;">Last seen</td>
2011-03-28 14:21:28 +00:00
<td><strong>Remark</strong></td>
</tr>
<?
} // End new class header
2013-02-22 08:00:24 +00:00
2011-03-28 14:21:28 +00:00
// Display staff members for this class
$Row = ($Row == 'a') ? 'b' : 'a';
?>
<tr class="row<?=$Row?>">
<td class="nobr">
2013-04-13 08:00:19 +00:00
<?=Users::format_username($ID, false, false, false) ?>
2011-03-28 14:21:28 +00:00
</td>
<td class="nobr">
2013-04-13 08:00:19 +00:00
<? if (check_paranoia('lastseen', $Paranoia, $Class)) {
echo time_diff($LastAccess);
} else {
echo 'Hidden by staff member';
}
?>
2011-03-28 14:21:28 +00:00
</td>
<td class="nobr">
<?=$Remark?>
</td>
</tr>
<? } ?>
</table>
2013-02-22 08:00:24 +00:00
2011-03-28 14:21:28 +00:00
</div>
</div>
<?
2012-10-11 08:00:15 +00:00
View::show_footer();
2011-03-28 14:21:28 +00:00
?>