X-Git-Url: https://git.p6c8.net/jirafeau_mojo42.git/blobdiff_plain/5d7c0d3ce08074fff55e7731490fe786cd6101e6..f55334d19ee35f6a163f574a54546449f7d44ca0:/admin.php?ds=sidebyside diff --git a/admin.php b/admin.php index 44a0134..bcc291b 100644 --- a/admin.php +++ b/admin.php @@ -1,7 +1,7 @@ + * Copyright (C) 2015 Jerome Jutteau * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Affero General Public License as @@ -110,8 +110,6 @@ if (php_sapi_name() == "cli") { * Be sure PHP's safe mode is off. */ @set_time_limit(0); - /* Remove errors. */ - @error_reporting(0); /* Show admin interface if not downloading a file. */ if (!(isset($_POST['action']) && strcmp($_POST['action'], 'download') == 0)) { @@ -160,6 +158,19 @@ if (php_sapi_name() == "cli") { +
+ + + + + + + + + + + +
@@ -228,6 +239,12 @@ if (php_sapi_name() == "cli") { echo '

'; echo t('CLEANED_FILES_CNT') . ' : ' . $total; echo '

'; + } elseif (strcmp($_POST['action'], 'size') == 0) { + $size = jirafeau_dir_size($cfg['var_root']); + $human_size = jirafeau_human_size($size); + echo '
' . NL; + echo '

' . t('SIZE_DATA') . ': ' . $human_size .'

'; + echo '
'; } elseif (strcmp($_POST['action'], 'list') == 0) { jirafeau_admin_list("", "", ""); } elseif (strcmp($_POST['action'], 'search_by_name') == 0) { @@ -258,7 +275,6 @@ if (php_sapi_name() == "cli") { $r = fopen(VAR_FILES . $p . $l['hash'], 'r'); while (!feof($r)) { print fread($r, 1024); - ob_flush(); } fclose($r); }