mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Merge pull request #4666 from tractorcow/pulls/3.2/changelogs
DOCS Update changelogs to include PDO upgrade instructions
This commit is contained in:
commit
e28156c138
@ -69,7 +69,8 @@ This is my `_ss_environment.php` file. I have it placed in `/var`, as each of th
|
||||
|
||||
:::php
|
||||
<?php
|
||||
// These three defines set the database connection details.
|
||||
// These four define set the database connection details.
|
||||
define('SS_DATABASE_CLASS', 'MySQLPDODatabase');
|
||||
define('SS_DATABASE_SERVER', 'localhost');
|
||||
define('SS_DATABASE_USERNAME', 'root');
|
||||
define('SS_DATABASE_PASSWORD', '<password>');
|
||||
@ -106,7 +107,7 @@ This is my `_ss_environment.php` file. I have it placed in `/var`, as each of th
|
||||
| Name | Description |
|
||||
| ---- | ----------- |
|
||||
| `TEMP_FOLDER` | Absolute file path to store temporary files such as cached templates or the class manifest. Needs to be writeable by the webserver user. Defaults to *silverstripe-cache* in the webroot, and falls back to *sys_get_temp_dir()*. See *getTempFolder()* in *framework/core/TempPath.php*.|
|
||||
| `SS_DATABASE_CLASS` | The database class to use, MySQLDatabase, MSSQLDatabase, etc. defaults to MySQLDatabase.|
|
||||
| `SS_DATABASE_CLASS` | The database class to use, MySQLPDODatabase, MySQLDatabase, MSSQLDatabase, etc. defaults to MySQLDatabase.|
|
||||
| `SS_DATABASE_SERVER`| The database server to use, defaulting to localhost.|
|
||||
| `SS_DATABASE_USERNAME`| The database username (mandatory).|
|
||||
| `SS_DATABASE_PASSWORD`| The database password (mandatory).|
|
||||
|
@ -3,8 +3,8 @@
|
||||
## Contents
|
||||
|
||||
* [Major Changes](#major-changes)
|
||||
* [Removed API](#deprecated-classesmethods-removed)
|
||||
* [New API](#new-and-changed-api)
|
||||
* [Deprecated classes/methods](#deprecated-classesmethods-removed)
|
||||
* [New and changed API](#new-and-changed-api)
|
||||
* [Bugfixes](#bugfixes)
|
||||
* [Upgrading Notes](#upgrading-notes)
|
||||
|
||||
@ -183,6 +183,32 @@ The following functionality deprecated in 3.0 has been removed:
|
||||
|
||||
## Upgrading Notes
|
||||
|
||||
### Enable PDO
|
||||
|
||||
Although this is not a mandatory upgrade step, the new `[api:PDOConnector]` class offers improved database
|
||||
performance and security, and should be integrated into any project using 3.2.
|
||||
|
||||
In order to update your connector you can do so in one of two ways, depending on whether or not
|
||||
your project is using `_ss_environment.php` to configure your database, or via `mysite/_config.php`
|
||||
|
||||
If using `_ss_environment.php`:
|
||||
|
||||
|
||||
:::php
|
||||
define('SS_DATABASE_CLASS', 'MySQLPDODatabase');
|
||||
|
||||
|
||||
If using `mysite/_config.php`:
|
||||
|
||||
|
||||
:::php
|
||||
global $databaseConfig;
|
||||
$databaseConfig = array(
|
||||
"type" => "MySQLPDODatabase"
|
||||
// other config settings
|
||||
);
|
||||
|
||||
|
||||
### Disable `LastVisited` and `NumVisits` counter
|
||||
|
||||
These fields were deprecated in 3.1 due to performance concerns, and should be disabled unless required by
|
||||
|
Loading…
Reference in New Issue
Block a user