mirror of
https://github.com/silverstripe/silverstripe-installer
synced 2024-10-22 17:05:33 +02:00
BUGFIX Fixed messages of "Database '' exists" instead of "Database 'SS_mysite' exists"
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/phpinstaller/branches/2.4@98665 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
af4238e275
commit
8dd4256bfc
@ -719,7 +719,7 @@ class InstallRequirements {
|
|||||||
if($databaseConfig['type'] == 'MySQLDatabase') {
|
if($databaseConfig['type'] == 'MySQLDatabase') {
|
||||||
$conn = @mysql_connect($databaseConfig['server'], $databaseConfig['username'], $databaseConfig['password']);
|
$conn = @mysql_connect($databaseConfig['server'], $databaseConfig['username'], $databaseConfig['password']);
|
||||||
if(@mysql_select_db($databaseConfig['database'])) {
|
if(@mysql_select_db($databaseConfig['database'])) {
|
||||||
$okay = "Database '$database' exists";
|
$okay = "Database '$databaseConfig[database]' exists";
|
||||||
} else {
|
} else {
|
||||||
if(@mysql_query("CREATE DATABASE testing123")) {
|
if(@mysql_query("CREATE DATABASE testing123")) {
|
||||||
mysql_query("DROP DATABASE testing123");
|
mysql_query("DROP DATABASE testing123");
|
||||||
@ -728,7 +728,7 @@ class InstallRequirements {
|
|||||||
}
|
}
|
||||||
} elseif($databaseConfig['type'] == 'MSSQLDatabase') {
|
} elseif($databaseConfig['type'] == 'MSSQLDatabase') {
|
||||||
if(@mysql_select_db($databaseConfig['database'])) {
|
if(@mysql_select_db($databaseConfig['database'])) {
|
||||||
$okay = "Database '$database' exists";
|
$okay = "Database '$databaseConfig[database]' exists";
|
||||||
} else {
|
} else {
|
||||||
if(function_exists('mssql_connect') && @mssql_query("CREATE DATABASE testing123")) {
|
if(function_exists('mssql_connect') && @mssql_query("CREATE DATABASE testing123")) {
|
||||||
mssql_query("DROP DATABASE testing123");
|
mssql_query("DROP DATABASE testing123");
|
||||||
|
Loading…
Reference in New Issue
Block a user