diff options
author | plegall <plg@piwigo.org> | 2005-04-30 20:37:43 +0000 |
---|---|---|
committer | plegall <plg@piwigo.org> | 2005-04-30 20:37:43 +0000 |
commit | 7b5bb0e3fcbbd835a0184dccb8eeeb52d49d4349 (patch) | |
tree | 5867c5b356bc43a25be8164743e793ebd910fe28 | |
parent | 6f269bc0358cbbc1e14acc52ac8146c1a64bc159 (diff) |
- bug 95 fixed : "default maxwidth and maxheight not registered". In fact,
these informations were registered, but not tested and displayed. Tests
and siplay were added.
git-svn-id: http://piwigo.org/svn/branches/branch-1_4@779 68402e56-0260-453c-a942-63ccdbb3a9ee
-rw-r--r-- | admin/configuration.php | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/admin/configuration.php b/admin/configuration.php index 9b3ca801a..efc1ece79 100644 --- a/admin/configuration.php +++ b/admin/configuration.php @@ -94,6 +94,22 @@ if (isset($_POST['submit'])) { array_push($errors, $lang['periods_error']); } + // maxwidth + if (isset($_POST['default_maxwidth']) + and !empty($_POST['default_maxwidth']) + and (!preg_match($int_pattern, $_POST['default_maxwidth']) + or $_POST['default_maxwidth'] < 50)) + { + array_push($errors, $lang['maxwidth_error']); + } + // maxheight + if (isset($_POST['default_maxheight']) + and !empty($_POST['default_maxheight']) + and (!preg_match($int_pattern, $_POST['default_maxheight']) + or $_POST['default_maxheight'] < 50)) + { + array_push($errors, $lang['maxheight_error']); + } break; } case 'upload' : @@ -255,6 +271,8 @@ switch ($page['section']) 'CONF_STYLE_SELECT'=>style_select($conf['default_template'], 'default_template'), 'CONF_RECENT'=>$conf['recent_period'], 'NB_COMMENTS_PAGE'=>$conf['nb_comment_page'], + 'MAXWIDTH'=>$conf['default_maxwidth'], + 'MAXHEIGHT'=>$conf['default_maxheight'], 'EXPAND_YES'=>$expand_yes, 'EXPAND_NO'=>$expand_no, 'SHOW_COMMENTS_YES'=>$show_yes, |