mirror of
https://github.com/Piwigo/Piwigo.git
synced 2026-07-06 01:42:29 +02:00
Resolved issue 0000717: guest must be guest
git-svn-id: http://piwigo.org/svn/branches/branch-1_7@2054 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
@@ -187,6 +187,13 @@ else
|
||||
$template = new Template(PHPWG_ROOT_PATH.'template/'.$user['template'], $user['theme'] );
|
||||
}
|
||||
|
||||
if (isset($user['internal_status']['guest_must_be_guest'])
|
||||
and
|
||||
$user['internal_status']['guest_must_be_guest'] === true)
|
||||
{
|
||||
$header_msgs[] = l10n('guest_must_be_guest');
|
||||
}
|
||||
|
||||
if ($conf['gallery_locked'])
|
||||
{
|
||||
$header_msgs[] = $lang['gallery_locked_message'];
|
||||
|
||||
@@ -150,6 +150,12 @@ function build_user( $user_id, $use_cache )
|
||||
$user['is_the_guest'] = ($user['id'] == $conf['guest_id']);
|
||||
$user['is_the_default'] = ($user['id'] == $conf['default_user_id']);
|
||||
|
||||
if ($user['is_the_guest'] and $user['status'] <> 'guest')
|
||||
{
|
||||
$user['status'] = 'guest';
|
||||
$user['internal_status']['guest_must_be_guest'] = true;
|
||||
}
|
||||
|
||||
// calculation of the number of picture to display per page
|
||||
$user['nb_image_page'] = $user['nb_image_line'] * $user['nb_line_page'];
|
||||
|
||||
|
||||
@@ -632,4 +632,6 @@ $lang['Picture name: %s'] = 'Picture name: %s';
|
||||
$lang['Creation date: %s'] = 'Creation date: %s';
|
||||
$lang['Waiting page: %s'] = 'Waiting page: %s';
|
||||
$lang['Picture uploaded by %s'] = 'Picture uploaded by %s';
|
||||
// --------- Starting below: New or revised $lang ---- from version 1.7.1
|
||||
$lang['guest_must_be_guest'] = 'Bad status for user "guest", using default status. Please notify the webmaster.';
|
||||
?>
|
||||
|
||||
@@ -632,4 +632,6 @@ $lang['Picture name: %s'] = 'Nom de l\'image: %s';
|
||||
$lang['Creation date: %s'] = 'Date de création: %d';
|
||||
$lang['Waiting page: %s'] = 'Page en attente: %s';
|
||||
$lang['Picture uploaded by %s'] = 'Image téléchargée par %s';
|
||||
// --------- Starting below: New or revised $lang ---- from version 1.7.1
|
||||
$lang['guest_must_be_guest'] = 'Statut de l\'utilisateur "guest" non conforme, utilisation du statut par défaut. Veuillez prévenir le webmestre.';
|
||||
?>
|
||||
|
||||
Reference in New Issue
Block a user