aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormistic100 <mistic@piwigo.org>2013-01-05 10:04:10 +0000
committermistic100 <mistic@piwigo.org>2013-01-05 10:04:10 +0000
commit4b7b977db2a981e3c624cf3438323cf1bff0140c (patch)
tree69f36dae80b0de7da54c07c298db79f4e96192f7
parent46c1519fbe7a8ef0b0208757ffe5a7bce8a67510 (diff)
minor optimization on photos_add_direct
git-svn-id: http://piwigo.org/svn/trunk@19828 68402e56-0260-453c-a942-63ccdbb3a9ee
-rw-r--r--admin/include/photos_add_direct_prepare.inc.php2
-rw-r--r--admin/themes/default/template/photos_add_direct.tpl2
2 files changed, 3 insertions, 1 deletions
diff --git a/admin/include/photos_add_direct_prepare.inc.php b/admin/include/photos_add_direct_prepare.inc.php
index 0ec506cdf..f9443553d 100644
--- a/admin/include/photos_add_direct_prepare.inc.php
+++ b/admin/include/photos_add_direct_prepare.inc.php
@@ -108,7 +108,7 @@ if (pwg_image::get_library() == 'gd')
$upload_modes = array('html', 'multiple');
$upload_mode = isset($conf['upload_mode']) ? $conf['upload_mode'] : 'multiple';
-if (isset($_GET['upload_mode']) and in_array($_GET['upload_mode'], $upload_modes))
+if (isset($_GET['upload_mode']) and $upload_mode != $_GET['upload_mode'] and in_array($_GET['upload_mode'], $upload_modes))
{
$upload_mode = $_GET['upload_mode'];
conf_update_param('upload_mode', $upload_mode);
diff --git a/admin/themes/default/template/photos_add_direct.tpl b/admin/themes/default/template/photos_add_direct.tpl
index 3ebfff1d4..6794e0407 100644
--- a/admin/themes/default/template/photos_add_direct.tpl
+++ b/admin/themes/default/template/photos_add_direct.tpl
@@ -76,11 +76,13 @@ jQuery(document).ready(function(){
jQuery("#uploadWarningsSummary a.showInfo").click(function() {
jQuery("#uploadWarningsSummary").hide();
jQuery("#uploadWarnings").show();
+ return false;
});
jQuery("#showPermissions").click(function() {
jQuery(this).parent(".showFieldset").hide();
jQuery("#permissions").show();
+ return false;
});
{/literal}