From 47ca2de815467d9cd728ec87e16df71715ad14fa Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Wed, 6 Jul 2011 09:42:55 +0000 Subject: [PATCH] Enhancements in file upload --- htdocs/core/class/html.formfile.class.php | 11 ++++++----- htdocs/theme/auguria/style.css.php | 11 ++++++++++- htdocs/theme/bureau2crea/style.css.php | 18 ++++++++++++++---- htdocs/theme/cameleo/style.css.php | 19 ++++++++----------- htdocs/theme/eldy/style.css.php | 23 ++--------------------- htdocs/theme/freelug/style.css.php | 11 ++++++++++- htdocs/theme/yellow/style.css.php | 11 ++++++++++- 7 files changed, 60 insertions(+), 44 deletions(-) diff --git a/htdocs/core/class/html.formfile.class.php b/htdocs/core/class/html.formfile.class.php index b3792c9b612..3559969f429 100644 --- a/htdocs/core/class/html.formfile.class.php +++ b/htdocs/core/class/html.formfile.class.php @@ -22,7 +22,7 @@ * \file htdocs/core/class/html.formfile.class.php * \ingroup core * \brief File of class to offer components to list and upload files - * \version $Id: html.formfile.class.php,v 1.41 2011/07/06 09:25:06 eldy Exp $ + * \version $Id: html.formfile.class.php,v 1.42 2011/07/06 09:42:55 eldy Exp $ */ @@ -611,8 +611,9 @@ class FormFile if (empty($useinecm)) { print ''; - $pdirthumb='thumbs/'; - if (image_format_supported($file['name']) > 0) print ''; + $tmp=explode('.',$file['name']); + $minifile=$tmp[0].'_mini.'.$tmp[1]; + if (image_format_supported($file['name']) > 0) print ''; else print ' '; print ''; } @@ -774,12 +775,12 @@ class FormFile var max_file_size = \''.$max_file_size.'\'; // Initialize the jQuery File Upload widget: - $("#fileupload").fileupload({ + $("#fileupload").fileupload({ maxFileSize: max_file_size, done: function (e, data) { $.ajax(data).success(function () { location.href=\''.$_SERVER["PHP_SELF"].'?'.$_SERVER["QUERY_STRING"].'\'; - }); + }); }, destroy: function (e, data) { var that = $(this).data("fileupload"); diff --git a/htdocs/theme/auguria/style.css.php b/htdocs/theme/auguria/style.css.php index 3b1ce8cdc3d..debc0f1cef0 100644 --- a/htdocs/theme/auguria/style.css.php +++ b/htdocs/theme/auguria/style.css.php @@ -21,7 +21,7 @@ /** * \file htdocs/theme/auguria/style.css.php * \brief Fichier de style CSS du theme auguria - * \version $Id$ + * \version $Id: style.css.php,v 1.86 2011/07/06 09:42:55 eldy Exp $ */ //if (! defined('NOREQUIREUSER')) define('NOREQUIREUSER','1'); // Not disabled cause need to load personalized language @@ -1890,6 +1890,15 @@ span.cke_skin_kama { padding: 0 ! important; } +/* ============================================================================== */ +/* File upload */ +/* ============================================================================== */ + +.template-upload { + height: 72px !important; +} + + /* ============================================================================== */ /* Test using div instead of tables */ /* ============================================================================== */ diff --git a/htdocs/theme/bureau2crea/style.css.php b/htdocs/theme/bureau2crea/style.css.php index b80af676123..488a3ab72fc 100644 --- a/htdocs/theme/bureau2crea/style.css.php +++ b/htdocs/theme/bureau2crea/style.css.php @@ -23,7 +23,7 @@ /** * \file htdocs/theme/bureau2crea/style.css.php * \brief Fichier de style CSS du theme bureau2crea - * \version $Id: style.css.php,v 1.36 2011/07/01 14:01:46 simnandez Exp $ + * \version $Id: style.css.php,v 1.37 2011/07/06 09:42:55 eldy Exp $ */ //if (! defined('NOREQUIREUSER')) define('NOREQUIREUSER','1'); // Not disabled cause need to load personalized language @@ -468,7 +468,7 @@ li.tmenu a { li.tmenu a:hover { color: #a1ad23; } - + li.tmenu .tmenusel { color: #FFF; padding: 0px 10px 0px 10px; @@ -480,7 +480,7 @@ li.tmenu .tmenusel { border-bottom: 0px solid #555555; border-left: 1px solid #D0D0D0; border-top: 1px solid #D8D8D8; - background: #606060; + background: #606060; } @@ -512,7 +512,7 @@ li.tmenusel a:hover { li.tmenu a.tmenudisabled { color: #CCC; } - + /* --- end nav --- */ @@ -2046,3 +2046,13 @@ div.leftContent { } span.cke_skin_kama { padding: 0 !important; } .cke_wrapper { padding: 4px !important; } + + + +/* ============================================================================== */ +/* File upload */ +/* ============================================================================== */ + +.template-upload { + height: 72px !important; +} diff --git a/htdocs/theme/cameleo/style.css.php b/htdocs/theme/cameleo/style.css.php index 1b7122e80a9..5782c5a3d62 100644 --- a/htdocs/theme/cameleo/style.css.php +++ b/htdocs/theme/cameleo/style.css.php @@ -23,7 +23,7 @@ /** * \file htdocs/theme/eldy/style.css.php * \brief Fichier de style CSS du theme Cameleo - * \version $Id$ + * \version $Id: style.css.php,v 1.5 2011/07/06 09:42:55 eldy Exp $ */ //if (! defined('NOREQUIREUSER')) define('NOREQUIREUSER','1'); // Not disabled cause need to load personalized language @@ -2068,14 +2068,11 @@ A.none, A.none:active, A.none:visited, A.none:hover { span.cke_skin_kama { padding: 0 !important; } .cke_wrapper { padding: 4px !important; } -#label -{ - text-align: right; - color: #666; -} -#value -{ - font-weight: bold; - padding: 0 0px 0 10px; -} +/* ============================================================================== */ +/* File upload */ +/* ============================================================================== */ + +.template-upload { + height: 72px !important; +} \ No newline at end of file diff --git a/htdocs/theme/eldy/style.css.php b/htdocs/theme/eldy/style.css.php index bc390481a9c..ac7eec87a29 100644 --- a/htdocs/theme/eldy/style.css.php +++ b/htdocs/theme/eldy/style.css.php @@ -21,7 +21,7 @@ /** * \file htdocs/theme/eldy/style.css.php * \brief Fichier de style CSS du theme Eldy - * \version $Id: style.css.php,v 1.81 2011/07/06 09:25:06 eldy Exp $ + * \version $Id: style.css.php,v 1.82 2011/07/06 09:42:55 eldy Exp $ */ //if (! defined('NOREQUIREUSER')) define('NOREQUIREUSER','1'); // Not disabled cause need to load personalized language @@ -1886,28 +1886,9 @@ span.cke_skin_kama { padding: 0 !important; } /* ============================================================================== */ -/* CKEditor */ +/* File upload */ /* ============================================================================== */ -.fileupload-content -{ - padding: 0 !important; -} -.ui-corner-br -{ - border-bottom-right-radius: 0 !important; -} -.ui-corner-bl -{ - border-bottom-left-radius: 0 !important; -} -.files td { - height: 18px !important; - padding: 0; -} -.files { - margin: 0px; -} .template-upload { height: 72px !important; } \ No newline at end of file diff --git a/htdocs/theme/freelug/style.css.php b/htdocs/theme/freelug/style.css.php index e0d4c713de8..0e5cb135e87 100644 --- a/htdocs/theme/freelug/style.css.php +++ b/htdocs/theme/freelug/style.css.php @@ -20,7 +20,7 @@ /** * \file htdocs/theme/freelug/style.css.php * \brief Fichier de style CSS du theme Freelug - * \version $Id$ + * \version $Id: style.css.php,v 1.40 2011/07/06 09:42:55 eldy Exp $ */ //if (! defined('NOREQUIREUSER')) define('NOREQUIREUSER','1'); // Not disabled cause need to load personalized language @@ -1469,3 +1469,12 @@ A.none, A.none:active, A.none:visited, A.none:hover { } span.cke_skin_kama { padding: 0 ! important; } + + +/* ============================================================================== */ +/* File upload */ +/* ============================================================================== */ + +.template-upload { + height: 72px !important; +} diff --git a/htdocs/theme/yellow/style.css.php b/htdocs/theme/yellow/style.css.php index 368f80bbd1a..b72b9f67261 100644 --- a/htdocs/theme/yellow/style.css.php +++ b/htdocs/theme/yellow/style.css.php @@ -20,7 +20,7 @@ /** * \file htdocs/theme/yellow/style.css.php * \brief Fichier de style CSS du theme Yellow - * \version $Id$ + * \version $Id: style.css.php,v 1.41 2011/07/06 09:42:55 eldy Exp $ */ //if (! defined('NOREQUIREUSER')) define('NOREQUIREUSER','1'); // Not disabled cause need to load personalized language @@ -1518,3 +1518,12 @@ A.none, A.none:active, A.none:visited, A.none:hover { } span.cke_skin_kama { padding: 0 ! important; } + + +/* ============================================================================== */ +/* File upload */ +/* ============================================================================== */ + +.template-upload { + height: 72px !important; +}