forum.coppermine-gallery.net
Dev Board => cpg1.4 Testing/Bugs => cpg1.4 Testing/Bugs: FIXED/CLOSED => Topic started by: jules_b on March 28, 2006, 02:29:58 pm
-
Hi,
I'm using version 1.4.4 with the phpBB bridge. Everything's working lovely apart from this probem:
Members of the Registered group are unable to edit picture titles and descriptions in User Galleries after the photos have been uploaded.
User clicks on their album and clicks on an individual picture. Clicks EDIT FILE INFORMATION and can enter the information. Clicks on APPLY MODIFICATIONS and receives the following error: You don't have permission to access this page.
Same user is able to edit titles and description information by clicking on EDIT FILES next to the album.
I saw this thread but the line causing problems is not commented out in my editpics.php so it can't be that.
http://forum.coppermine-gallery.net/index.php?topic=17802.0
The gallery is at:
http://www.orionmountaineering.com/cpg144/
Grateful for any suggestions.
Jules.
-
I am also having the same issue. I checked the file in link jules_b posted and the line the ref to comment out is not commented in mine.
Any ideas?
-
I have the same problem but ....
the following setting has effect on this error :
Allow users to retain control over their pics in public galleries
If changed to "yes" the user can edit the file.
-
Bug is likely here in editOnePic.php
$result = cpg_db_query("SELECT p.* FROM {$CONFIG['TABLE_PICTURES']} AS p, {$CONFIG['TABLE_ALBUMS']} AS a WHERE a.aid = p.aid AND pid = '$pid'");
if (!mysql_num_rows($result)) cpg_die(CRITICAL_ERROR, $lang_errors['non_exist_ap'], __FILE__, __LINE__);
$pic = mysql_fetch_array($result);
mysql_free_result($result);
if (!(GALLERY_ADMIN_MODE || $pic['category'] == FIRST_USER_CAT + USER_ID || ($CONFIG['users_can_edit_pics'] && $pic['owner_id'] == USER_ID)) || !USER_ID) cpg_die(ERROR, $lang_errors['access_denied'], __FILE__, __LINE__);
The query does not retrieve the category, so the test below fails.
Try changing the p.* to *
-
From what I can tell this corrects the issue. Thank you I will have some more users test.
-
This fix does indeed cure the problem.
Thanks
-
Fixed as of svn revision 3032.