From c6470d49b0df4095fef5dc96584601cc8eb93cee Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Thu, 20 Sep 2018 16:21:08 +0200 Subject: [PATCH] FIX The max size for upload file was not corectly shown --- htdocs/core/class/html.formfile.class.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/htdocs/core/class/html.formfile.class.php b/htdocs/core/class/html.formfile.class.php index 5cca7233dd4..f9fc04d47de 100644 --- a/htdocs/core/class/html.formfile.class.php +++ b/htdocs/core/class/html.formfile.class.php @@ -127,11 +127,12 @@ class FormFile if (preg_match('/g$/i',$maxphp)) $maxphp=$maxphp*1024*1024; if (preg_match('/t$/i',$maxphp)) $maxphp=$maxphp*1024*1024*1024; // Now $max and $maxphp are in Kb - if ($maxphp > 0) $max=min($max,$maxphp); + $maxmin = $max; + if ($maxphp > 0) $maxmin=min($max,$maxphp); - if ($max > 0) + if ($maxmin > 0) { - $out .= ''; + $out .= ''; } $out .= '