mirror of
https://github.com/cytopia/devilbox.git
synced 2025-03-11 06:53:54 +00:00
Ensure Adminer and phpMyAdmin work with old PHP versions
This commit is contained in:
parent
60b2d99c09
commit
a459597759
1934
.devilbox/www/htdocs/vendor/adminer-4.6.3-en.php
vendored
Normal file
1934
.devilbox/www/htdocs/vendor/adminer-4.6.3-en.php
vendored
Normal file
File diff suppressed because one or more lines are too long
@ -86,7 +86,7 @@ class Html
|
|||||||
'menu' => array(
|
'menu' => array(
|
||||||
array(
|
array(
|
||||||
'name' => 'Adminer',
|
'name' => 'Adminer',
|
||||||
'path' => '/vendor/adminer-4.7.0-en.php',
|
'path' => '__ADMINER__',
|
||||||
'target' => '_blank'
|
'target' => '_blank'
|
||||||
),
|
),
|
||||||
array(
|
array(
|
||||||
@ -383,7 +383,10 @@ HTML;
|
|||||||
|
|
||||||
// Replace
|
// Replace
|
||||||
if ($el['path'] == '__PHPMYADMIN__') {
|
if ($el['path'] == '__PHPMYADMIN__') {
|
||||||
$el['path'] = (strpos(loadClass('Php')->getVersion(), '5.4') !== false) ? '/vendor/phpmyadmin-4.0/index.php' : '/vendor/phpmyadmin-4.8/index.php';
|
$el['path'] = (version_compare(loadClass('Php')->getVersion(), '5.4', '<=')) ? '/vendor/phpmyadmin-4.0/index.php' : '/vendor/phpmyadmin-4.8/index.php';
|
||||||
|
}
|
||||||
|
if ($el['path'] == '__ADMINER__') {
|
||||||
|
$el['path'] = (version_compare(loadClass('Php')->getVersion(), '5.3', '<=')) ? '/vendor/adminer-4.6.3-en.php' : '/vendor/adminer-4.7.0-en.php';
|
||||||
}
|
}
|
||||||
|
|
||||||
$target = isset($el['target']) ? 'target="'.$el['target'].'"' : '';
|
$target = isset($el['target']) ? 'target="'.$el['target'].'"' : '';
|
||||||
|
Loading…
x
Reference in New Issue
Block a user