how to disable user deletions

bob@neoforts.com - September 20, 2006 - 18:42

Is it possible through a module or manually editiing certain files, to disable the ability of users to delete uploaded files?

I would like to know exactly which files were uploaded on my site, and if users can upload and delete them at will then I lose that ability.

remove their access control

VeryMisunderstood - September 20, 2006 - 20:37

remove their access control to edit. if they cannot edit, they cannot delete. these two functions seem to be tied together.

How can I allow users to edit but not delete?

Zhigang Suo - September 25, 2006 - 00:56

Drupal can save all revisions.

I have a site that allow users to post and comment on scholarly materials. Suppose I post an idea, which is wrong. But before I realize that it is wrong, you discover the error, and write a post pointing it out. Naturally you make a hyperlink pointing to my post. If I then delete my post, your post loses the context.

How can allow users to edit freely, but disable "delete"?

Using the Forms API in a small module would be one way

nevets - September 25, 2006 - 01:06

You could write a small module that uses the form_alter hook to remove the delete button from form edit forms. Because you probably want some way of deleting stuff you also probably want a permission that allows selected people to actually delete. With a little more work you could also enable/disable the function on a per content basis.

Any existing module that allows edit but disallows delete?

Zhigang Suo - January 13, 2007 - 16:29

Thank you for the reply. I don't know how to write these codes. Is there any existing module that allows edit but disallows delete?

subscribing

marcoBauli - January 19, 2007 - 15:39

yes, i'm looking for the same thing on a per-content-type basis..

*checking out Simpleaccess, Nodeaccess and Node_access_arbitrator modules right now*


--- UPDATE ---

seems that:

- Simpleaccess: can only limit who can *view* a node, but not who can delete it.

- Nodeaccess: can limit also who deletes it, but actually didn't work for me on 4.7.2 and CCK

- Node_access_Arbitrator: seems it works only for forums and workflows for now....documentation is non-existant, so i might be wrong, but i couldn't make it work for this purpose..

Guess the hook_form_alter() way is the one at this point....?

I'd like something like this

nickistre - February 4, 2007 - 02:08

I'd like something like this too. I've been looking for a way to prevent users from deleting their posts but allow them to edit, especially in the forum.

Ideally, permissions for nodes and comments should be divided in the following matter:

View, Create, Edit, Delete,
View Self, Edit Self, Delete Self.

This way, I can let certain roles edit and/or delete their own content, and give moderators the general edit and delete roles.

 
 

Drupal is a registered trademark of Dries Buytaert.