summaryrefslogtreecommitdiff
path: root/install.php
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2008-08-28 08:40:33 +0000
committerDries Buytaert <dries@buytaert.net>2008-08-28 08:40:33 +0000
commit395199859d169409f62f0676bf5265278967d5b1 (patch)
tree8d742d2f9641c3f776e901e50540bc359fe3065f /install.php
parent762ca25ecfb0bcc418d00bfdafea80485ac001ca (diff)
downloadbrdo-395199859d169409f62f0676bf5265278967d5b1.tar.gz
brdo-395199859d169409f62f0676bf5265278967d5b1.tar.bz2
- Patch #299330 by justinrandell, Damien Tournoud: select MySQL driver by default -- less clicking
Diffstat (limited to 'install.php')
-rw-r--r--install.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/install.php b/install.php
index 30355e4ad..c606aecbe 100644
--- a/install.php
+++ b/install.php
@@ -194,7 +194,8 @@ function install_change_settings($profile = 'default', $install_locale = '') {
$conf_path = './' . conf_path(FALSE, TRUE);
$settings_file = $conf_path . '/settings.php';
- $database = $databases['default']['default'];
+ $database = isset($databases['default']['default']) ? $databases['default']['default'] : array();
+
// We always need this because we want to run form_get_errors.
include_once './includes/form.inc';
install_task_list('database');
@@ -237,7 +238,7 @@ function install_settings_form(&$form_state, $profile, $install_locale, $setting
'#title' => st('Database driver'),
'#required' => TRUE,
'#options' => $drivers,
- '#default_value' => !empty($database['driver']) ? $database['driver'] : current($drivers),
+ '#default_value' => !empty($database['driver']) ? $database['driver'] : current(array_keys($drivers)),
'#description' => st('The type of database your @drupal data will be stored in.', array('@drupal' => drupal_install_profile_name())),
);
$database_description = st('The name of the database your @drupal data will be stored in. It must exist on your server before @drupal can be installed.', array('@drupal' => drupal_install_profile_name()));