forked from omeka/plugin-UserTags
-
Notifications
You must be signed in to change notification settings - Fork 0
/
config_form.php
26 lines (25 loc) · 1.02 KB
/
config_form.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
<?php $view = get_view(); ?>
<div class="field">
<div class="two columns alpha">
<label><?php echo __('Roles with private tags')?></label>
</div>
<div class="inputs five columns omega">
<p class="explanation"><?php echo __("Check the roles whose tags should be private. Their tags will be visible only to themselves. This only applies to tags on Items."); ?></p>
<div class="input-block">
<?php
$privateRoles = unserialize(get_option('user-tags-private-roles'));
$userRoles = get_user_roles();
echo '<ul>';
foreach($userRoles as $role=>$label) {
echo '<li>';
echo $view->formCheckbox('user_tags_private_roles[]', $role,
array('checked'=> in_array($role, $privateRoles) ? 'checked' : '')
);
echo $label;
echo '</li>';
}
echo '</ul>';
?>
</div>
</div>
</div>