aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Module
diff options
context:
space:
mode:
authorphani00 <phani00@gmail.com>2018-12-16 20:35:20 +0000
committerphani00 <phani00@gmail.com>2018-12-16 20:35:20 +0000
commit1c07428f8968dc52c0bead76509fcd5400a8c5fd (patch)
tree28cb24ea2bd91e8b076457b40017ed019a3d10e0 /Zotlabs/Module
parentc854ec068641db3b9fce3e5b9e3ffdc59d8d621e (diff)
downloadvolse-hubzilla-1c07428f8968dc52c0bead76509fcd5400a8c5fd.tar.gz
volse-hubzilla-1c07428f8968dc52c0bead76509fcd5400a8c5fd.tar.bz2
volse-hubzilla-1c07428f8968dc52c0bead76509fcd5400a8c5fd.zip
add warning if upload_filesize < 4MB.
Diffstat (limited to 'Zotlabs/Module')
-rw-r--r--Zotlabs/Module/Setup.php6
1 files changed, 6 insertions, 0 deletions
diff --git a/Zotlabs/Module/Setup.php b/Zotlabs/Module/Setup.php
index c0716ca7c..b2d42418e 100644
--- a/Zotlabs/Module/Setup.php
+++ b/Zotlabs/Module/Setup.php
@@ -441,13 +441,19 @@ class Setup extends \Zotlabs\Web\Controller {
require_once 'include/environment.php';
$help = '';
+ $mem_warning = '';
$result = getPhpiniUploadLimits();
+ if($result['post_max_size'] < 4194304 || $result['max_upload_filesize'] < 4194304) {
+ $mem_warning = '<strong>' .t('This is not sufficient to upload larger images or files. You should be able to upload at least 4 MB at once.') . '</strong>';
+ }
$help = sprintf(t('Your max allowed total upload size is set to %s. Maximum size of one file to upload is set to %s. You are allowed to upload up to %d files at once.'),
userReadableSize($result['post_max_size']),
userReadableSize($result['max_upload_filesize']),
$result['max_file_uploads']
);
+ $help .= $mem_warning;
+
$help .= '<br><br>' . t('You can adjust these settings in the server php.ini file.');
$this->check_add($checks, t('PHP upload limits'), true, false, $help);