Merge branch 'ent-12970-cambiar-mensaje-de-error-php-inferior-a-8-2' into 'develop'
Ent 12970 cambiar mensaje de error php inferior a 8 2 See merge request artica/pandorafms!6992
This commit is contained in:
commit
b458a85a59
|
@ -16,7 +16,35 @@ if ($issues) {
|
|||
if (PHP_SAPI === 'cli' || PHP_SAPI === 'phpdbg') {
|
||||
fwrite(STDERR, 'Composer detected issues in your platform:' . PHP_EOL.PHP_EOL . implode(PHP_EOL, $issues) . PHP_EOL.PHP_EOL);
|
||||
} elseif (!headers_sent()) {
|
||||
echo 'Composer detected issues in your platform:' . PHP_EOL.PHP_EOL . str_replace('You are running '.PHP_VERSION.'.', '', implode(PHP_EOL, $issues)) . PHP_EOL.PHP_EOL;
|
||||
require_once __DIR__.'/../../include/functions_ui.php';
|
||||
|
||||
$url = str_replace('/var/www/html/', '', __DIR__);
|
||||
$url = str_replace('/vendor/composer', '', $url);
|
||||
|
||||
echo '<link rel="stylesheet" type="text/css" href="include/styles/pandora.css">';
|
||||
?>
|
||||
|
||||
<style>
|
||||
body {
|
||||
display: block;
|
||||
}
|
||||
</style>
|
||||
|
||||
<?php
|
||||
|
||||
$random_backgrounds = scandir('/var/www/html/'.$url. '/images/backgrounds/random_backgrounds');
|
||||
unset($random_backgrounds[0], $random_backgrounds[1]);
|
||||
$random_background = array_rand($random_backgrounds);
|
||||
|
||||
echo '<div style="width:100%;min-height: 100%;position: absolute; display:flex;align-items:center;justify-content:center;background-size:cover !important; background-position: center: !important; background: linear-gradient(rgba(255, 255, 255, .20), rgba(255, 255, 255, .20)), url('.$url. '/../images/backgrounds/random_backgrounds/'.$random_backgrounds[$random_background].');">';
|
||||
echo '<center><div align="middle" class="license_databox w600px pdd_10px" style="background-color: white;">';
|
||||
echo '<img style="width: 500px; margin-top: 30px;" src="images/custom_logo/logo-default-pandorafms.png"><h2> Composer detected issues in your platform:</h2>';
|
||||
echo '<div class="w80p height_80px" style="text-align:left;font-size: larger">';
|
||||
echo sprintf(
|
||||
'PandoraFMS requires PHP 8.2 to work properly and the version %s has been detected. Please update the PHP version of the system.',
|
||||
PHP_VERSION,
|
||||
);
|
||||
echo '</div></div></center></div>';
|
||||
}
|
||||
}
|
||||
trigger_error(
|
||||
|
|
Loading…
Reference in New Issue