Update header message when gallery is locked or unlocked.

git-svn-id: http://piwigo.org/svn/trunk@9544 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
patdenice
2011-03-05 16:14:41 +00:00
parent 69f6f974b4
commit c2a5373184
+10
View File
@@ -109,6 +109,16 @@ if (isset($_POST['submit']))
{
case 'main' :
{
if (empty($_POST['gallery_locked']) and $conf['gallery_locked'])
{
$tpl_var = & $template->get_template_vars('header_msgs');
$msg_key = array_search(l10n('The gallery is locked for maintenance. Please, come back later.'), $tpl_var);
unset($tpl_var[$msg_key]);
}
elseif (!empty($_POST['gallery_locked']) and !$conf['gallery_locked'])
{
$template->append('header_msgs', l10n('The gallery is locked for maintenance. Please, come back later.'));
}
foreach( $main_checkboxes as $checkbox)
{
$_POST[$checkbox] = empty($_POST[$checkbox])?'false':'true';