<?php
$users=$PSA_SYS->get_users();
if($users===FALSE){
$PSA_SYS->error();
}
?>
<h2><?php echo _("System Users") ?></h2>
<p><a href="<?php echo $_SERVER['PHP_SELF'] ?>?psaSec=user_add" title="<?php echo _("Add User") ?>"><?php echo _("Add User") ?></a></p>
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<th><?php echo _("Username") ?></th>
<th><?php echo _("Real Name") ?></th>
<th><?php echo _("E-mail") ?></th>
<th><?php echo _("Active") ?></th>
<th> </th>
</tr>
<?php
$i=0;
while (list($username,$details)=@each($users)) {
$style = ($i&1) ? ' class="dataRowAlt"' : ' class="dataRow"';
echo ' <tr',$style,'>',"\n",
' <td>',$username,'</td>',"\n",
' <td>',$details['name'],'</td>',"\n",
' <td><a href="mailto:',$details['email'],'" title="',_("E-mail"),'">',$details['email'],'</a></td>',"\n",
' <td>';
echo ($details['active']) ? _("Yes") : _("No");
echo '</td>',"\n",
' <td>',
'[<a href="',$_SERVER['PHP_SELF'],'?psaSec=user_edit&PSA_id=',$username,'" title="',_("Edit"),'">',_("Edit"),'</a>]',
' [<a href="',$_SERVER['PHP_SELF'],'?psaSec=user_delete&PSA_id=',$username,'" title="',_("Delete"),'">',_("Delete"),'</a>]',
'</td>',"\n",
' </tr>',"\n";
++$i;
}
?>
</table>