diff options
Diffstat (limited to 'Neutron-trunk/cms-special/admin/about')
-rw-r--r--[-rwxr-xr-x] | Neutron-trunk/cms-special/admin/about/index.php | 117 |
1 files changed, 1 insertions, 116 deletions
diff --git a/Neutron-trunk/cms-special/admin/about/index.php b/Neutron-trunk/cms-special/admin/about/index.php index 1551ff0..7d45b3e 100755..100644 --- a/Neutron-trunk/cms-special/admin/about/index.php +++ b/Neutron-trunk/cms-special/admin/about/index.php @@ -1,116 +1 @@ -<?php require_once "../../../resources/private/relative.php"; getRelativeDetails("cms-special"); ?> -<?php $pageConfig = [ "domName" => "Mise à jour et sécurité", "headerName" => "Mise à jour et sécurité" ]; require_once $_SERVER['DOCUMENT_ROOT'] . "/cms-special/admin/\$resources/precontent.php"; ?> - <?php - - $currentVersionP = file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/api/version"); - $currentVersion = $currentVersionP; - - ?> - <h3><?= $lang["admin-about"]["info"] ?></h3> - <ul><li> - <?php - - echo("" . $lang['admin-about']['version']['prefix'] . " <b>" . $currentVersionP . "</b>"); - echo("</li>"); - - $size = 0; - getData($_SERVER['DOCUMENT_ROOT']); - $sizestr = $size . " " . $lang["sizes"]["bytes"] . ""; - if ($size > 1024) { - if ($size > 1048576) { - if ($size > 1073741824) { - $sizestr = round($size / 1073741824, 3) . " " . $lang["sizes"]["gibibytes"] . ""; - } else { - $sizestr = round($size / 1048576, 3) . " " . $lang["sizes"]["mebibytes"] . ""; - } - } else { - $sizestr = round($size / 1024, 3) . " " . $lang["sizes"]["kibibytes"] . ""; - } - } else { - $sizestr = $size . " " . $lang["sizes"]["bytes"] . ""; - } - - echo("<li>" . $lang["admin-about"]["diskspace"][0] . " <b>" . $sizestr . "</b> " . $lang["admin-about"]["diskspace"][1] . "</li>"); - - ?> - </ul> - <h3><?= $lang["admin-about"]["disk"] ?></h3> - <div id="storagebar" value="0" max="1"></div> - <span style="margin-left: 10px;"></span> - <?php - - $globalSize = $size; - - $size = 0; - getData($_SERVER['DOCUMENT_ROOT'] . "/api"); - $mpcmsSize = $size; - getData($_SERVER['DOCUMENT_ROOT'] . "/cms-special"); - $mpcmsSize = $mpcmsSize + $size; - getData($_SERVER['DOCUMENT_ROOT'] . "/widgets"); - $mpcmsSize = $mpcmsSize + $size; - - getData($_SERVER['DOCUMENT_ROOT'] . "/resources/css"); - $mpcmsSize = $mpcmsSize + $size; - getData($_SERVER['DOCUMENT_ROOT'] . "/resources/fonts"); - $mpcmsSize = $mpcmsSize + $size; - getData($_SERVER['DOCUMENT_ROOT'] . "/resources/i18n"); - $mpcmsSize = $mpcmsSize + $size; - getData($_SERVER['DOCUMENT_ROOT'] . "/resources/image"); - $mpcmsSize = $mpcmsSize + $size; - getData($_SERVER['DOCUMENT_ROOT'] . "/resources/js"); - $mpcmsSize = $mpcmsSize + $size; - getData($_SERVER['DOCUMENT_ROOT'] . "/resources/lib"); - $mpcmsSize = $mpcmsSize + $size; - getData($_SERVER['DOCUMENT_ROOT'] . "/resources/private"); - $mpcmsSize = $mpcmsSize + $size; - - $size = 0; - getData($_SERVER['DOCUMENT_ROOT'] . "/data"); - $dataSize = $size; - - $calSize = filesize($_SERVER['DOCUMENT_ROOT'] . "/data/webcontent/caldb.json"); - $confSize = filesize($_SERVER['DOCUMENT_ROOT'] . "/data/webcontent/sitename") + filesize($_SERVER['DOCUMENT_ROOT'] . "/data/webcontent/system.log") + filesize($_SERVER['DOCUMENT_ROOT'] . "/data/webcontent/widgets.json") + filesize($_SERVER['DOCUMENT_ROOT'] . "/data/webcontent/password") + filesize($_SERVER['DOCUMENT_ROOT'] . "/data/webcontent/footer"); - if (file_exists($_SERVER['DOCUMENT_ROOT'] . "/data/webcontent/widget-notes-data")) { - $confSize = $confSize + filesize($_SERVER['DOCUMENT_ROOT'] . "/data/webcontent/widget-notes-data"); - } - if (file_exists($_SERVER['DOCUMENT_ROOT'] . "/data/webcontent/widget-contact-data")) { - $confSize = $confSize + filesize($_SERVER['DOCUMENT_ROOT'] . "/data/webcontent/widget-contact-data"); - } - - $size = 0; - getData($_SERVER['DOCUMENT_ROOT'] . "/resources/upload"); - $resSize = $size; - - $globalSize = $resSize + $mpcmsSize + $confSize + $dataSize + $calSize; - - ?> - <div style="display:grid;grid-template-columns:1fr 1fr 1fr 1fr;"> - <span><span style="margin-right:5px;border-radius:999px;vertical-align:middle;background-color:#8bcf69;position:relative;width:15px;height:15px;display:inline-block;"></span><span style="margin-right:30px;"><?= $lang["admin-about"]["categories"]['system'] ?> (<?= round(($mpcmsSize*100)/$globalSize, 2) ?>%)</span></span> - <span><span style="margin-right:5px;border-radius:999px;vertical-align:middle;background-color:#e6d450;position:relative;width:15px;height:15px;display:inline-block;"></span><span style="margin-right:30px;"><?= $lang["admin-about"]["categories"]['config'] ?> (<?= round(($dataSize*100)/$globalSize, 2) ?>%)</span></span> - <span><span style="margin-right:5px;border-radius:999px;vertical-align:middle;background-color:#cf82bf;position:relative;width:15px;height:15px;display:inline-block;"></span><span style="margin-right:30px;"><?= $lang["admin-about"]["categories"]['resources'] ?> (<?= round(($resSize*100)/$globalSize, 2) ?>%)</span></span> - <span><span style="margin-right:5px;border-radius:999px;vertical-align:middle;background-color:gray;position:relative;width:15px;height:15px;display:inline-block;"></span><span style="margin-right:30px;"><?= $lang["admin-about"]["categories"]['misc'] ?></span></span> - </div> - <!-- <?= $globalSize - ($mpcmsSize + $dataSize + $resSize) ?> - <?= "<br>" ?> - <?= (($mpcmsSize + $dataSize + $resSize) * 100)/$globalSize ?> --> - <style> - #storagebar { - height: 12px; - width: calc(100% - 16px); - margin: 8px; - border-radius: 5px; - box-shadow: 0 5px 5px -5px #999 inset; - background-image: linear-gradient( - 90deg, - #8bcf69 <?= round(($mpcmsSize*100)/$globalSize, 2) ?>%, - #e6d450 <?= round(($mpcmsSize*100)/$globalSize, 2) ?>%, - #e6d450 <?= round(($dataSize*100)/$globalSize, 2) ?>%, - #cf82bf <?= round(($dataSize*100)/$globalSize, 2) ?>%, - #cf82bf <?= round(($resSize*100)/$globalSize, 2) ?>%, - gray <?= round(($resSize*100)/$globalSize, 2) ?>%, - gray 100% - ); - background-size: 100% 100%; - } - </style> -<?php require_once $_SERVER['DOCUMENT_ROOT'] . "/cms-special/admin/\$resources/postcontent.php"; ?> +<?php require_once "../../../resources/private/relative.php"; getRelativeDetails("cms-special"); ?><?php header("Location: {$GLOBALS["SYSTEM_ROOT"]}/cms-special/admin-v2"); require $_SERVER['DOCUMENT_ROOT'] . "/api/electrode/quit.php"; quit(); ?>
\ No newline at end of file |