aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrvelices <rv-github@modusoptimus.com>2012-01-12 05:57:43 +0000
committerrvelices <rv-github@modusoptimus.com>2012-01-12 05:57:43 +0000
commit65590487d4f07d81a3e47899c2454df187d3f23a (patch)
treef801ccc9c0297ee2c1720eacf064a9c3d5b3ac31
parent286bef319c58ce95e1e75facaeed8cee74461b4d (diff)
remove max photo width/height from user profile because not used anymore
git-svn-id: http://piwigo.org/svn/trunk@12877 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to '')
-rw-r--r--admin/profile.php2
-rw-r--r--admin/themes/default/template/profile_content.tpl12
-rw-r--r--admin/themes/default/template/user_list.tpl24
-rw-r--r--admin/user_list.php8
-rw-r--r--profile.php18
-rw-r--r--themes/default/template/profile_content.tpl12
6 files changed, 5 insertions, 71 deletions
diff --git a/admin/profile.php b/admin/profile.php
index 584539bfb..5de9d139a 100644
--- a/admin/profile.php
+++ b/admin/profile.php
@@ -2,7 +2,7 @@
// +-----------------------------------------------------------------------+
// | Piwigo - a PHP based photo gallery |
// +-----------------------------------------------------------------------+
-// | Copyright(C) 2008-2011 Piwigo Team http://piwigo.org |
+// | Copyright(C) 2008-2012 Piwigo Team http://piwigo.org |
// | Copyright(C) 2003-2008 PhpWebGallery Team http://phpwebgallery.net |
// | Copyright(C) 2002-2003 Pierrick LE GALL http://le-gall.net/pierrick |
// +-----------------------------------------------------------------------+
diff --git a/admin/themes/default/template/profile_content.tpl b/admin/themes/default/template/profile_content.tpl
index 5109b84c8..8c0e913ad 100644
--- a/admin/themes/default/template/profile_content.tpl
+++ b/admin/themes/default/template/profile_content.tpl
@@ -81,18 +81,6 @@
<span class="property">{'Show number of hits'|@translate}</span>
{html_radios name='show_nb_hits' options=$radio_options selected=$NB_HITS}
</li>
- <li>
- <span class="property">
- <label for="maxwidth">{'Maximum photo width'|@translate}</label>
- </span>
- <input type="text" size="4" maxlength="4" name="maxwidth" id="maxwidth" value="{$MAXWIDTH}">
- </li>
- <li>
- <span class="property">
- <label for="maxheight">{'Maximum photo height'|@translate}</label>
- </span>
- <input type="text" size="4" maxlength="4" name="maxheight" id="maxheight" value="{$MAXHEIGHT}">
- </li>
</ul>
</fieldset>
diff --git a/admin/themes/default/template/user_list.tpl b/admin/themes/default/template/user_list.tpl
index 8085d5a10..62f488769 100644
--- a/admin/themes/default/template/user_list.tpl
+++ b/admin/themes/default/template/user_list.tpl
@@ -254,30 +254,6 @@
</td>
</tr>
- <tr>
- <td>{'Maximum photo width'|@translate}</td>
- <td>
- <label><input type="radio" name="maxwidth_action" value="leave" checked="checked"> {'leave'|@translate}</label>
- <label><input type="radio" name="maxwidth_action" value="unset"> {'unset'|@translate}</label>
- <label><input type="radio" name="maxwidth_action" value="set" id="maxwidth_action_set"> {'set to'|@translate}</label>
- <input onmousedown="document.getElementById('maxwidth_action_set').checked = true;"
- type="text" size="4" maxlength="4" name="maxwidth" value="{$MAXWIDTH}">
- </td>
- </tr>
-
-
- <tr>
- <td>{'Maximum photo height'|@translate}</td>
- <td>
- <label><input type="radio" name="maxheight_action" value="leave" checked="checked"> {'leave'|@translate}</label>
- <label><input type="radio" name="maxheight_action" value="unset"> {'unset'|@translate}</label>
- <label><input type="radio" name="maxheight_action" value="set" id="maxheight_action_set"> {'set to'|@translate}</label>
- <input onmousedown="document.getElementById('maxheight_action_set').checked = true;"
- type="text" size="4" maxlength="4" name="maxheight" value="{$MAXHEIGHT}">
- </td>
- </tr>
-
-
</table>
</fieldset>
diff --git a/admin/user_list.php b/admin/user_list.php
index 4c0852e38..33c3485f1 100644
--- a/admin/user_list.php
+++ b/admin/user_list.php
@@ -385,8 +385,8 @@ DELETE FROM '.USER_GROUP_TABLE.'
$formfields =
array('nb_image_page', 'theme', 'language',
- 'recent_period', 'maxwidth', 'expand', 'show_nb_comments',
- 'show_nb_hits', 'maxheight', 'status', 'enabled_high',
+ 'recent_period', 'expand', 'show_nb_comments',
+ 'show_nb_hits', 'status', 'enabled_high',
'level');
$true_false_fields = array('expand', 'show_nb_comments',
@@ -560,8 +560,6 @@ if (isset($_POST['pref_submit']))
$template->assign(
array(
'NB_IMAGE_PAGE' => $_POST['nb_image_page'],
- 'MAXWIDTH' => $_POST['maxwidth'],
- 'MAXHEIGHT' => $_POST['maxheight'],
'RECENT_PERIOD' => $_POST['recent_period'],
));
}
@@ -571,8 +569,6 @@ else
$template->assign(
array(
'NB_IMAGE_PAGE' => $default_user['nb_image_page'],
- 'MAXWIDTH' => $default_user['maxwidth'],
- 'MAXHEIGHT' => $default_user['maxheight'],
'RECENT_PERIOD' => $default_user['recent_period'],
));
}
diff --git a/profile.php b/profile.php
index ab1bcf677..acdf9822b 100644
--- a/profile.php
+++ b/profile.php
@@ -49,7 +49,7 @@ if (!defined('PHPWG_ROOT_PATH'))
if (isset($_POST['reset_to_default']))
{
$fields = array(
- 'nb_image_page', 'maxwidth', 'maxheight', 'expand',
+ 'nb_image_page', 'expand',
'show_nb_comments', 'show_nb_hits', 'recent_period', 'show_nb_hits'
);
@@ -124,18 +124,6 @@ function save_profile_from_post($userdata, &$errors)
$errors[] = l10n('The number of photos per page must be a not null scalar');
}
- if ($_POST['maxwidth'] != ''
- and (!preg_match($int_pattern, $_POST['maxwidth'])
- or $_POST['maxwidth'] < 50))
- {
- $errors[] = l10n('Maximum width must be a number superior to 50');
- }
- if ($_POST['maxheight']
- and (!preg_match($int_pattern, $_POST['maxheight'])
- or $_POST['maxheight'] < 50))
- {
- $errors[] = l10n('Maximum height must be a number superior to 50');
- }
// periods must be integer values, they represents number of days
if (!preg_match($int_pattern, $_POST['recent_period'])
or $_POST['recent_period'] <= 0)
@@ -221,7 +209,7 @@ function save_profile_from_post($userdata, &$errors)
{
// update user "additional" informations (specific to Piwigo)
$fields = array(
- 'nb_image_page', 'language', 'maxwidth', 'maxheight',
+ 'nb_image_page', 'language',
'expand', 'show_nb_comments', 'show_nb_hits', 'recent_period', 'theme'
);
@@ -268,8 +256,6 @@ function load_profile_in_template($url_action, $url_redirect, $userdata)
'ALLOW_USER_CUSTOMIZATION'=>$conf['allow_user_customization'],
'NB_IMAGE_PAGE'=>$userdata['nb_image_page'],
'RECENT_PERIOD'=>$userdata['recent_period'],
- 'MAXWIDTH'=>@$userdata['maxwidth'],
- 'MAXHEIGHT'=>@$userdata['maxheight'],
'EXPAND' =>$userdata['expand'] ? 'true' : 'false',
'NB_COMMENTS'=>$userdata['show_nb_comments'] ? 'true' : 'false',
'NB_HITS'=>$userdata['show_nb_hits'] ? 'true' : 'false',
diff --git a/themes/default/template/profile_content.tpl b/themes/default/template/profile_content.tpl
index f9f7b8530..9736e101a 100644
--- a/themes/default/template/profile_content.tpl
+++ b/themes/default/template/profile_content.tpl
@@ -80,18 +80,6 @@
<span class="property">{'Show number of hits'|@translate}</span>
{html_radios name='show_nb_hits' options=$radio_options selected=$NB_HITS}
</li>
- <li>
- <span class="property">
- <label for="maxwidth">{'Maximum photo width'|@translate}</label>
- </span>
- <input type="text" size="4" maxlength="4" name="maxwidth" id="maxwidth" value="{$MAXWIDTH}">
- </li>
- <li>
- <span class="property">
- <label for="maxheight">{'Maximum photo height'|@translate}</label>
- </span>
- <input type="text" size="4" maxlength="4" name="maxheight" id="maxheight" value="{$MAXHEIGHT}">
- </li>
</ul>
</fieldset>
{/if}