How to find and amend the User who created an item?

I need to change the user who added an item so that Admins or Super users can do the uploading and then allow ‘Contributor’ users to edit the item’s Dublin Core fields.

Is there any way to do this?

I tinkered with a plugin to do this a while ago. Seems to still work, but is mostly untested.

Thanks for the quick reply - I’m prepared to edit the code manually of it’s possible to do it this way for a batch of items, but I don’t know where to find the info on which user uploaded an item, Can you help with this please?

If you have the $item object, you can do $item->getOwner() to get the user, and $item->setOwner($user); to set the owner. Once you start making changes, those will no longer be the person who created the item, of course – just the person who has all the permissions to edit the item.

To do batch changes, you’d have to get all the items you want to change and loop through them all to make the changes.

Cool!!! I’m a bit of a newbie to PHP but with a bit of time I’m sure I can work it out. Many, many thanks.

Hello, @H_Gregg.

See whether this other thread could help you with your task: https://forum.omeka.org/t/help-needed-changing-reassignownership-plugin-to-include-batch-edit

Regards.