opensmtpdadmin/templates/admin_list-admin.tpl
2022-08-18 14:01:52 +02:00

32 lines
1.6 KiB
Smarty

<?php
if (!empty($list_admins)) {
$list_admins_count = count($list_admins);
if (is_array($list_admins) && $list_admins_count > 0) {
print "<table id=\"admin_table\">\n";
print " <tr class=\"header\">\n";
print " <td>" . $PALANG['pAdminList_admin_username'] . "</td>\n";
print " <td>" . $PALANG['pAdminList_admin_count'] . "</td>\n";
print " <td>" . $PALANG['pAdminList_admin_modified'] . "</td>\n";
print " <td>" . $PALANG['pAdminList_admin_active'] . "</td>\n";
print " <td colspan=\"2\">&nbsp;</td>\n";
print " </tr>\n";
for ($i = 0; $i < $list_admins_count; $i++) {
if ((is_array($list_admins) and $list_admins_count > 0)) {
print " <tr class=\"hilightoff\" onMouseOver=\"className='hilighton';\" onMouseOut=\"className='hilightoff';\">\n";
print " <td><a href=\"list-domain.php?username=" . $list_admins[$i] . "\">" . $list_admins[$i] . "</a></td>";
print " <td>" . $admin_properties[$i]['domain_count'] . "</td>";
print " <td>" . $admin_properties[$i]['modified'] . "</td>";
$active = ($admin_properties[$i]['active'] == 1) ? $PALANG['YES'] : $PALANG['NO'];
print " <td><a href=\"edit-active-admin.php?username=" . $list_admins[$i] . "\">" . $active . "</a></td>";
print " <td><a href=\"edit-admin.php?username=" . $list_admins[$i] . "\">" . $PALANG['edit'] . "</a></td>";
print " <td><a href=\"delete.php?table=admin&where=username&delete=" . $list_admins[$i] . "\" onclick=\"return confirm ('" . $PALANG['confirm'] . $PALANG['pAdminList_admin_username'] . ": " . $list_admins[$i] . "')\">" . $PALANG['del'] . "</a></td>";
print " </tr>\n";
}
}
print "</table>\n";
}
}
?>