Gazelle/sections/tools/managers/permissions_alter.php

59 lines
2.1 KiB
PHP
Raw Normal View History

2011-03-28 14:21:28 +00:00
<?
function display_perm($Key,$Title) {
global $Values;
$Perm='<input type="checkbox" name="perm_'.$Key.'" id="'.$Key.'" value="1"';
if (!empty($Values[$Key])) { $Perm.=" checked"; }
$Perm.=' /> <label for="'.$Key.'">'.$Title.'</label><br />';
echo $Perm;
}
show_header('Manage Permissions','validate');
2012-09-15 08:00:25 +00:00
echo $Val->GenerateJS('permissionsform');
2011-03-28 14:21:28 +00:00
?>
2012-09-15 08:00:25 +00:00
<form class="manage_form" name="permissions" id="permissionsform" method="post" action="" onsubmit="return formVal();">
2011-03-28 14:21:28 +00:00
<input type="hidden" name="action" value="permissions" />
<input type="hidden" name="auth" value="<?=$LoggedUser['AuthKey']?>" />
<input type="hidden" name="id" value="<?=display_str($_REQUEST['id']); ?>" />
<div class="linkbox">
[<a href="tools.php?action=permissions">Back to permission list</a>]
[<a href="tools.php">Back to Tools</a>]
</div>
2012-09-01 08:00:24 +00:00
<table class="permission_head layout">
2011-03-28 14:21:28 +00:00
<tr>
<td class="label">Permission Name</td>
<td><input type="text" name="name" id="name" value="<?=(!empty($Name) ? display_str($Name) : '')?>" /></td>
</tr>
<tr>
<td class="label">Class Level</td>
<td><input type="text" name="level" id="level" value="<?=(!empty($Level) ? display_str($Level) : '')?>" /></td>
</tr>
2012-03-28 08:00:20 +00:00
<tr>
<td class="label">Secondary Class</td>
<td><input type="checkbox" name="secondary" value="1" <? if (!empty($Secondary)) { ?>checked<? } ?> /></td>
</tr>
2011-03-28 14:21:28 +00:00
<tr>
<td class="label">Show on Staff page</td>
<td><input type="checkbox" name="displaystaff" value="1" <? if (!empty($DisplayStaff)) { ?>checked<? } ?> /></td>
</tr>
2011-10-17 08:00:16 +00:00
<tr>
<td class="label">Maximum number of personal collages</td>
<td><input type="text" name="maxcollages" size="5" value="<?=$Values['MaxCollages']?>" /></td>
</tr>
2012-03-28 08:00:20 +00:00
<tr>
<td class="label">Additional Forums</td>
<td><input type="text" size="30" name="forums" value="<?=display_str($Forums)?>" /></td>
</tr>
2011-03-28 14:21:28 +00:00
<? if (is_numeric($_REQUEST['id'])) { ?>
<tr>
<td class="label">Current users in this class</td>
<td><?=number_format($UserCount)?></td>
</tr>
<? } ?>
</table>
<?
include(SERVER_ROOT."/classes/permissions_form.php");
permissions_form();
?>
</form>
2012-09-15 08:00:25 +00:00
<? show_footer(); ?>