From c1518a278a3626ba2f2fcb28c5180ca7ff7f9b54 Mon Sep 17 00:00:00 2001 From: kenjis Date: Mon, 18 Mar 2024 19:02:03 +0900 Subject: [PATCH 1/3] docs: move content in table to section below --- .../source/database/configuration.rst | 34 ++++++++++++------- 1 file changed, 21 insertions(+), 13 deletions(-) diff --git a/user_guide_src/source/database/configuration.rst b/user_guide_src/source/database/configuration.rst index 2239c65799e2..24ba92eaeb05 100644 --- a/user_guide_src/source/database/configuration.rst +++ b/user_guide_src/source/database/configuration.rst @@ -136,9 +136,9 @@ and decode it in the constructor in the Config class: .. _database-config-explanation-of-values: -********************** -Explanation of Values: -********************** +********************* +Explanation of Values +********************* ================ =========================================================================================================== Name Config Description @@ -164,15 +164,9 @@ Explanation of Values: applications where you might run manually written queries, and need the prefix to still be customizable by the end user. **schema** The database schema, default value varies by driver. (Used by ``Postgre`` and ``SQLSRV``.) -**encrypt** Whether or not to use an encrypted connection. - ``SQLSRV`` driver accepts true/false - ``MySQLi`` driver accepts an array with the following options: - * ``ssl_key`` - Path to the private key file - * ``ssl_cert`` - Path to the public key certificate file - * ``ssl_ca`` - Path to the certificate authority file - * ``ssl_capath`` - Path to a directory containing trusted CA certificates in PEM format - * ``ssl_cipher`` - List of *allowed* ciphers to be used for the encryption, separated by colons (``:``) - * ``ssl_verify`` - true/false; Whether to verify the server certificate or not (``MySQLi`` only) +**encrypt** Whether or not to use an encrypted connection. (``MySQLi`` and ``SQLSRV`` only). + ``SQLSRV`` driver accepts true/false. + See :ref:`MySQLi encrypt ` for ``MySQLi`` settings. **compress** Whether or not to use client compression (``MySQLi`` only). **strictOn** true/false (boolean) - Whether to force "Strict Mode" connections, good for ensuring strict SQL while developing an application (``MySQLi`` only). @@ -205,4 +199,18 @@ the ``'hostname'`` setting. CodeIgniter's MySQLi driver will notice this and con connection properly. .. literalinclude:: configuration/011.php - :lines: 11-18 \ No newline at end of file + :lines: 11-18 + +.. _mysqli-encrypt: + +encrypt +------- + +MySQLi driver accepts an array with the following options: + +* ``ssl_key`` - Path to the private key file +* ``ssl_cert`` - Path to the public key certificate file +* ``ssl_ca`` - Path to the certificate authority file +* ``ssl_capath`` - Path to a directory containing trusted CA certificates in PEM format +* ``ssl_cipher`` - List of *allowed* ciphers to be used for the encryption, separated by colons (``:``) +* ``ssl_verify`` - true/false; Whether to verify the server certificate or not From 1009b8f33c51e2d73c150f3436b7408d266f7f9a Mon Sep 17 00:00:00 2001 From: kenjis Date: Mon, 18 Mar 2024 19:05:16 +0900 Subject: [PATCH 2/3] docs: list available drivers first --- .../source/database/configuration.rst | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/user_guide_src/source/database/configuration.rst b/user_guide_src/source/database/configuration.rst index 24ba92eaeb05..48ad3853742a 100644 --- a/user_guide_src/source/database/configuration.rst +++ b/user_guide_src/source/database/configuration.rst @@ -159,25 +159,25 @@ Explanation of Values **pConnect** true/false (boolean) - Whether to use a persistent connection. **DBDebug** true/false (boolean) - Whether to throw exceptions or not when database errors occur. **charset** The character set used in communicating with the database. -**DBCollat** The character collation used in communicating with the database (``MySQLi`` only). +**DBCollat** (``MySQLi`` only) The character collation used in communicating with the database. **swapPre** A default table prefix that should be swapped with ``DBPrefix``. This is useful for distributed applications where you might run manually written queries, and need the prefix to still be customizable by the end user. -**schema** The database schema, default value varies by driver. (Used by ``Postgre`` and ``SQLSRV``.) -**encrypt** Whether or not to use an encrypted connection. (``MySQLi`` and ``SQLSRV`` only). +**schema** (``Postgre`` and ``SQLSRV`` only) The database schema, default value varies by driver. +**encrypt** (``MySQLi`` and ``SQLSRV`` only) Whether or not to use an encrypted connection. ``SQLSRV`` driver accepts true/false. See :ref:`MySQLi encrypt ` for ``MySQLi`` settings. -**compress** Whether or not to use client compression (``MySQLi`` only). -**strictOn** true/false (boolean) - Whether to force "Strict Mode" connections, good for ensuring strict SQL - while developing an application (``MySQLi`` only). +**compress** (``MySQLi`` only) Whether or not to use client compression. +**strictOn** (``MySQLi`` only) true/false (boolean) - Whether to force "Strict Mode" connections, good for ensuring + strict SQL while developing an application. **port** The database port number - Empty string ``''`` for default port (or dynamic port with ``SQLSRV``). -**foreignKeys** true/false (boolean) - Whether or not to enable Foreign Key constraint (``SQLite3`` only). +**foreignKeys** (``SQLite3`` only) true/false (boolean) - Whether or not to enable Foreign Key constraint. .. important:: SQLite3 Foreign Key constraint is disabled by default. See `SQLite documentation `_. To enforce Foreign Key constraint, set this config item to true. -**busyTimeout** milliseconds (int) - Sleeps for a specified amount of time when a table is locked (``SQLite3`` only). -**numberNative** true/false (boolean) - Whether or not to enable MYSQLI_OPT_INT_AND_FLOAT_NATIVE (``MySQLi`` only). +**busyTimeout** (``SQLite3`` only) milliseconds (int) - Sleeps for a specified amount of time when a table is locked. +**numberNative** (``MySQLi`` only) true/false (boolean) - Whether or not to enable MYSQLI_OPT_INT_AND_FLOAT_NATIVE. ================ =========================================================================================================== .. note:: Depending on what database driver you are using (``MySQLi``, ``Postgre``, From 6931822bbcc3e1fd75bb01bb5064f360957f477f Mon Sep 17 00:00:00 2001 From: kenjis Date: Mon, 18 Mar 2024 19:07:15 +0900 Subject: [PATCH 3/3] docs: move MySQLi description up --- user_guide_src/source/database/configuration.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/user_guide_src/source/database/configuration.rst b/user_guide_src/source/database/configuration.rst index 48ad3853742a..a0ef5c8cd1d8 100644 --- a/user_guide_src/source/database/configuration.rst +++ b/user_guide_src/source/database/configuration.rst @@ -165,8 +165,8 @@ Explanation of Values customizable by the end user. **schema** (``Postgre`` and ``SQLSRV`` only) The database schema, default value varies by driver. **encrypt** (``MySQLi`` and ``SQLSRV`` only) Whether or not to use an encrypted connection. - ``SQLSRV`` driver accepts true/false. See :ref:`MySQLi encrypt ` for ``MySQLi`` settings. + ``SQLSRV`` driver accepts true/false. **compress** (``MySQLi`` only) Whether or not to use client compression. **strictOn** (``MySQLi`` only) true/false (boolean) - Whether to force "Strict Mode" connections, good for ensuring strict SQL while developing an application.