Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
#13 2007-08-23 19:57:23
- ellen
- Member
- From: Switzerland
- Registered: 2006-04-18
- Posts: 41
Re: Restrict author permissons
Dear Ruud,
Thank you for your help. I’ve just found out that one has to replace $name
with $author
and then it works as intended! Since I don’T want to replace the txp_image.php file each time when I have to delete a users image I wonder if it is possible to modify the following line in a way that the delete button is shown to the image’S author and to me as the admin?
($txp_user == $author ? dLink('image', 'image_delete', 'id', $id, '', '', '', false, array($page, $sort, $dir, $crit, $search_method)) : '')
Offline
Re: Restrict author permissons
Replace
($txp_user == $author ?
with
(($txp_user == $author or has_privs('admin.edit')) ?
That would give the publisher the right to delete images at all times. If you want image delete rights to all users that can also delete articles, replace ‘admin.edit’ with ‘article.delete’.
Last edited by ruud (2007-08-23 20:14:38)
Offline
#15 2007-08-23 20:29:19
- ellen
- Member
- From: Switzerland
- Registered: 2006-04-18
- Posts: 41
Re: Restrict author permissons
Cooooool! Now it is perfect. This is the link to the site: Click me
Thanks again and Good night!
Offline