diff options
author | andi <andi@splitbrain.org> | 2005-06-03 22:55:01 +0200 |
---|---|---|
committer | andi <andi@splitbrain.org> | 2005-06-03 22:55:01 +0200 |
commit | 8ef6b7cad0b5839ab823182392161af60f15fd69 (patch) | |
tree | e143cd40ad8581810fe78fcfac00dcb660a035da /inc/admin_acl.php | |
parent | 5ef370d246543eb020ac46989b5ab8717e10a5b0 (diff) | |
download | rpg-8ef6b7cad0b5839ab823182392161af60f15fd69.tar.gz rpg-8ef6b7cad0b5839ab823182392161af60f15fd69.tar.bz2 |
Mediafile Deletion and Overwrite Handling #200
This patch enhances the ACL feature by adding another Permission called DELETE - this permission
allows a user to delete or overwrite existing mediafiles. Users with UPLOAD permission are no longer
allowed to overwrite media files.
Users whith DELETE permissions now need to check an additional checkbox to overwrite existing files,
this is to prevent accidently deletions.
Please note: If no ACL is used UPLOAD rights are assumed for everybody - not DELETE rights. This
changes the behaviour from previous versions as UPLOAD does not allow overwriting anymore.
darcs-hash:20050603205501-9977f-1d219b23a79bb097ed0e0b8184dc6d5d8aad578b.gz
Diffstat (limited to 'inc/admin_acl.php')
-rw-r--r-- | inc/admin_acl.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/inc/admin_acl.php b/inc/admin_acl.php index 5dc907049..fcf9d9ae3 100644 --- a/inc/admin_acl.php +++ b/inc/admin_acl.php @@ -28,7 +28,7 @@ function admin_acl_handler(){ if($type == '@') $user = '@'.$user; if($user == '@all') $user = '@ALL'; //special group! (now case insensitive) $perm = (int) $perm; - if($perm > AUTH_UPLOAD) $perm = AUTH_UPLOAD; + if($perm > AUTH_DELETE) $perm = AUTH_DELETE; //FIXME sanitize scope!!! //nothing to do? @@ -374,7 +374,7 @@ function admin_acl_html_checkboxes($setperm,$ispage){ static $label = 0; //number labels $ret = ''; - foreach(array(AUTH_READ,AUTH_EDIT,AUTH_CREATE,AUTH_UPLOAD) as $perm){ + foreach(array(AUTH_READ,AUTH_EDIT,AUTH_CREATE,AUTH_UPLOAD,AUTH_DELETE) as $perm){ $label += 1; //general checkbox attributes |