mirror of
https://github.com/silverstripe/silverstripe-installer
synced 2024-10-22 15:05:33 +00:00
BUGFIX: #2527 - Fix mysql version detection on hosts with custom mysql version names (HakTom)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/phpinstaller/trunk@63903 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
a19daa0398
commit
056bc59ec8
@ -456,8 +456,11 @@ class InstallRequirements {
|
|||||||
$this->warning($testDetails);
|
$this->warning($testDetails);
|
||||||
} else {
|
} else {
|
||||||
list($majorRequested, $minorRequested) = explode('.', $version);
|
list($majorRequested, $minorRequested) = explode('.', $version);
|
||||||
list($majorHas, $minorHas) = explode('.', mysql_get_server_info());
|
$result = mysql_query('SELECT VERSION()');
|
||||||
|
$row=mysql_fetch_row($result);
|
||||||
|
$version = ereg_replace("([A-Za-z-])", "", $row[0]);
|
||||||
|
list($majorHas, $minorHas) = explode('.', substr(trim($version), 0, 3));
|
||||||
|
|
||||||
if(($majorHas > $majorRequested) || ($majorHas == $majorRequested && $minorHas >= $minorRequested)) {
|
if(($majorHas > $majorRequested) || ($majorHas == $majorRequested && $minorHas >= $minorRequested)) {
|
||||||
return true;
|
return true;
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user