Hello/Hi/Greetings,
Is there a way to allow a user to edit photo titles and descriptions without giving them admin status?
I have enabled the Community plugin, which allows users to provide titles and descriptions to photos at the same time they upload them, but not to edit titles and descriptions of photos already in an album, regardless of whether it is private or public.
I have experimented with giving a user admin status which does allow them to edit titles, etc. But it also gives that user too much access, like ability to create/delete other users, add/delete albums, etc.
I have also tried changing their 'privacy level' to Admins, but this doesn't seem to have any effect.
Any suggestions?
Piwigo version: 2.9.3
PHP version: 5.4.45-0+deb7u12
MySQL version: 5.5.59-0+deb7u1
Piwigo URL: http://hbuus.com/newgallery
Offline
Offline
Thanks for the quick response. As it happens, I already had that plugin enabled, but I still didn't see any control/link that would allow my non-admin user to edit titles/descriptions. However, I took a closer look at the link you posted for the 'Admin Tools' plugin, and I think figured out what I need to do. But it involves editing the database directly, so my next question is whether there's a less hacky way to what I want.
I am migrating an old menalto gallery version 1 to piwigo. I've been populating my galleries directory with sub-directories and photos and then using 'Administration > Tools > Synchronize' as the webmaster to populate my database. I have not been uploading photos as the non-admin user. But I just did that with a test photo and now I see the Edit and Delete links at the top of the page for that photo. Seems that the ability to edit or delete a photo is determined by the user id stored in the added_by column of the piwigo_images table. I confirmed this by manually changing the field for one of the photos I did not upload, and now I can edit title/description as the non-admin user.
I am comfortable using phpmyadmin to change so-called ownership of images by changing the added_by column to point to the user id I want to give permission to edit titles/descriptions. But that's not something most people would be comfortable with, plus I wonder if you really want to encourage folks to hack the database this way. And it means only one non-admin user can do such editing. Is hacking the database the way to get what I want?
Also I haven't created any groups yet. Is it possible for images to be owned by a group so more than one user can edit them?
Offline
you are overthinking
Last edited by executive (2018-04-11 10:56:39)
Offline
No, i'm not. That Edit button does NOT show up unless the added_by column is set to the user id of the non-admin user. Because that user did NOT upload the photos, but was actually added by the webmaster by virtue of the syncronize option only available to webmasters and admins, that Edit only shows up for my webmaster user. I got it to show up by directly manipulating the database and changing the added_by column to the non-admin user's id.
Please check for yourself. Create another user, give them access to an existing album, public or private, and you will see they don't have the edit button.
So my questions remain:
Is there any other way to change ownership of photos other than hacknig the databaser?
Is ther any way to give a group ownership of photos so more than one non-admin user can edit them?
Offline
And may I also point out the user login you used is one with Admin or Webmaster status. Non-admin users don't get the Administration button, EVER.
Offline
I checked. It works for me and I didn't hack anything. Check your options.
Last edited by executive (2018-04-11 23:17:26)
Offline
Well, darn, I thought I had figured out one piece of the security puzzle. I've been through the options, many, if not most, of which are not well documented, and nothing obvious jumps out. I suspect the best way for me to really understand what might be different between your setup and mine is to dig into the code, and figure out exactly what criteria must be met to enable the Edit button for a non-admin user. And that's likely to be tedious, at best, and frustrating, at worst.
Unless you can suggest some options to experiment with, I'm inclined to go with what I know will work with my setup, hacking the database.
Offline
OK. I thought it was obvious but here you go.
Offline
I've got EXACTLY those settings. But look at that second option:
Give access to quick edit to PHOTO OWNERS even if they are not admin
Which takes us back to what I thought I made clear in my second post. My non-admin user is NOT the owner of these photos. The owner is the webmaster who put them in the galleries directory and then used "Synchronize" to populate the database. The "photo owner" appears to be identified in the added_by column of the piwigo_images table. When I change that column to the user id of the non-admin user, they now get the Edit button. IOW if I hack the database, I can give my non-admin user access to the Edit button.
I repeat:
Is there any other way to change ownership of photos other than hacking the database?
Is there any way to give a group ownership of photos so more than one non-admin user can edit them?
Offline
there are plugins for that too
http://piwigo.org/ext/extension_view.php?eid=692
http://piwigo.org/ext/extension_view.php?eid=724
http://piwigo.org/ext/extension_view.php?eid=723
Last edited by executive (2018-04-13 01:20:27)
Offline
I think we finally understand each other, and I want you to know I appreciate your patience. I now have the answer to my first question:
Is there any other way to change ownership of photos other than hacking the database?
And it is the 'Change who added photo' plugin: http://piwigo.org/ext/extension_view.php?eid=692
The other plugins you link to sound interesting, and I can see how they would help make sure photos belong to the right owner. But, as far as I can tell, they don't address my second question:
Is there any way to give a group ownership of photos so more than one non-admin user can edit them?
Offline