diff --git a/auth/db/lang/en/auth_db.php b/auth/db/lang/en/auth_db.php index 857ae2c241c..e2daf5702bf 100644 --- a/auth/db/lang/en/auth_db.php +++ b/auth/db/lang/en/auth_db.php @@ -35,13 +35,13 @@ $string['auth_dbfieldpass'] = 'Name of the field containing passwords'; $string['auth_dbfieldpass_key'] = 'Password field'; $string['auth_dbfielduser'] = 'Name of the field containing usernames'; $string['auth_dbfielduser_key'] = 'Username field'; -$string['auth_dbhost'] = 'The computer hosting the database server. Use a system DSN entry if using ODBC.'; +$string['auth_dbhost'] = 'The computer hosting the database server. Use a system DSN entry if using ODBC. Use a PDO DSN entry if using PDO.'; $string['auth_dbhost_key'] = 'Host'; $string['auth_dbchangepasswordurl_key'] = 'Password-change URL'; $string['auth_dbinsertuser'] = 'Inserted user {$a->name} id {$a->id}'; $string['auth_dbinsertuserduplicate'] = 'Error inserting user {$a->username} - user with this username was already created through \'{$a->auth}\' plugin.'; $string['auth_dbinsertusererror'] = 'Error inserting user {$a}'; -$string['auth_dbname'] = 'Name of the database itself. Leave empty if using an ODBC DSN.'; +$string['auth_dbname'] = 'Name of the database itself. Leave empty if using an ODBC DSN. Leave empty if your PDO DSN already contains the database name.'; $string['auth_dbname_key'] = 'DB name'; $string['auth_dbpass'] = 'Password matching the above username'; $string['auth_dbpass_key'] = 'Password'; diff --git a/auth/db/settings.php b/auth/db/settings.php index 64479d114b8..da5622ae298 100644 --- a/auth/db/settings.php +++ b/auth/db/settings.php @@ -45,7 +45,7 @@ if ($ADMIN->fulltree) { $dbtypes = array("access", "ado_access", "ado", "ado_mssql", "borland_ibase", "csv", "db2", "fbsql", "firebird", "ibase", "informix72", "informix", "mssql", "mssql_n", "mssqlnative", "mysql", "mysqli", "mysqlt", "oci805", "oci8", "oci8po", "odbc", "odbc_mssql", "odbc_oracle", - "oracle", "postgres64", "postgres7", "postgres", "proxy", "sqlanywhere", "sybase", "vfp"); + "oracle", "pdo", "postgres64", "postgres7", "postgres", "proxy", "sqlanywhere", "sybase", "vfp"); foreach ($dbtypes as $dbtype) { $dboptions[$dbtype] = $dbtype; } diff --git a/enrol/database/lang/en/enrol_database.php b/enrol/database/lang/en/enrol_database.php index 22efa55f200..8fc2e39063d 100644 --- a/enrol/database/lang/en/enrol_database.php +++ b/enrol/database/lang/en/enrol_database.php @@ -26,7 +26,7 @@ $string['database:config'] = 'Configure database enrol instances'; $string['database:unenrol'] = 'Unenrol suspended users'; $string['dbencoding'] = 'Database encoding'; $string['dbhost'] = 'Database host'; -$string['dbhost_desc'] = 'Type database server IP address or host name. Use a system DSN name if using ODBC.'; +$string['dbhost_desc'] = 'Type database server IP address or host name. Use a system DSN name if using ODBC. Use a PDO DSN if using PDO.'; $string['dbname'] = 'Database name'; $string['dbname_desc'] = 'Leave empty if using a DSN name in database host.'; $string['dbpass'] = 'Database password'; diff --git a/enrol/database/settings.php b/enrol/database/settings.php index 9dc9ae3e705..f5dde91ead7 100644 --- a/enrol/database/settings.php +++ b/enrol/database/settings.php @@ -31,7 +31,7 @@ if ($ADMIN->fulltree) { $settings->add(new admin_setting_heading('enrol_database_exdbheader', get_string('settingsheaderdb', 'enrol_database'), '')); - $options = array('', "access","ado_access", "ado", "ado_mssql", "borland_ibase", "csv", "db2", "fbsql", "firebird", "ibase", "informix72", "informix", "mssql", "mssql_n", "mssqlnative", "mysql", "mysqli", "mysqlt", "oci805", "oci8", "oci8po", "odbc", "odbc_mssql", "odbc_oracle", "oracle", "postgres64", "postgres7", "postgres", "proxy", "sqlanywhere", "sybase", "vfp"); + $options = array('', "access", "ado_access", "ado", "ado_mssql", "borland_ibase", "csv", "db2", "fbsql", "firebird", "ibase", "informix72", "informix", "mssql", "mssql_n", "mssqlnative", "mysql", "mysqli", "mysqlt", "oci805", "oci8", "oci8po", "odbc", "odbc_mssql", "odbc_oracle", "oracle", "pdo", "postgres64", "postgres7", "postgres", "proxy", "sqlanywhere", "sybase", "vfp"); $options = array_combine($options, $options); $settings->add(new admin_setting_configselect('enrol_database/dbtype', get_string('dbtype', 'enrol_database'), get_string('dbtype_desc', 'enrol_database'), '', $options));