1
0
mirror of https://github.com/e107inc/e107.git synced 2025-01-17 20:58:30 +01:00

Issue #2040 - Max-upload-size pref is now respected by the Media-Manager.

This commit is contained in:
Cameron 2016-11-17 12:34:09 -08:00
parent 87487bfaf7
commit 6f24cbb997
2 changed files with 5 additions and 2 deletions

View File

@ -1082,8 +1082,11 @@ class media_admin_ui extends e_admin_ui
}
// if 'for' has no value, files are placed in /temp and not added to the db.
$maxFileSize = e107::pref('core', 'upload_maxfilesize','20M');
$text = "<h4>".IMALAN_145."</h4>";
$text .= '<div id="uploader" rel="'.e_JS.'plupload/upload.php?for='.$this->getQuery('for').'">
$text .= '<div id="uploader" data-max-size="'.str_replace('M','mb',$maxFileSize).'" rel="'.e_JS.'plupload/upload.php?for='.$this->getQuery('for').'">
<p>'.IMALAN_146.'</p>
</div>';
$text .= '<hr />';

View File

@ -540,7 +540,7 @@ $(document).ready(function()
// General settings
runtimes : "html5,html4",
url : upath,
max_file_size : "20mb",
max_file_size : $("#uploader").attr("data-max-size"),
chunk_size : "1mb",
unique_names : false,