mirror of
https://github.com/Piwigo/Piwigo.git
synced 2026-06-02 04:15:05 +02:00
picture_modify: do not show link to gallery if user level is too low
This commit is contained in:
@@ -183,6 +183,9 @@ UPDATE '.CATEGORIES_TABLE.'
|
||||
|
||||
$page['infos'][] = l10n('Photo informations updated');
|
||||
pwg_activity('photo', $_GET['image_id'], 'edit');
|
||||
|
||||
// refresh page cache
|
||||
$page['image'] = get_image_infos($_GET['image_id'], true);
|
||||
}
|
||||
|
||||
// tags
|
||||
@@ -379,6 +382,7 @@ while ($row = pwg_db_fetch_assoc($result))
|
||||
// 3. if URL category not available or reachable, use the first reachable
|
||||
// linked category
|
||||
// 4. if no category reachable, no jumpto link
|
||||
// 5. if level is too high for current user, no jumpto link
|
||||
|
||||
$query = '
|
||||
SELECT category_id
|
||||
@@ -420,7 +424,7 @@ else
|
||||
}
|
||||
}
|
||||
|
||||
if (isset($url_img))
|
||||
if (isset($url_img) and $user['level'] >= $page['image']['level'])
|
||||
{
|
||||
$template->assign( 'U_JUMPTO', $url_img );
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user