Skip to content

Commit 91c0c22

Browse files
committed
Merge branch '4.1'
* 4.1: Updated a file location Documented the framework.session.enabled option
2 parents 62c1d4c + 90c2b62 commit 91c0c22

File tree

1 file changed

+44
-0
lines changed

1 file changed

+44
-0
lines changed

reference/configuration/framework.rst

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,7 @@ Configuration
143143
* `cookie_path`_
144144
* `cookie_samesite`_
145145
* `cookie_secure`_
146+
* :ref:`enabled <reference-session-enabled>`
146147
* `gc_divisor`_
147148
* `gc_maxlifetime`_
148149
* `gc_probability`_
@@ -952,6 +953,49 @@ session persists.
952953
Starting in Symfony 3.4, session data is *only* written when the session data has
953954
changed. Previously, you needed to set this option to avoid that behavior.
954955

956+
.. _reference-session-enabled:
957+
958+
enabled
959+
.......
960+
961+
**type**: ``boolean`` **default**: ``true``
962+
963+
Whether to enable the session support in the framework.
964+
965+
.. configuration-block::
966+
967+
.. code-block:: yaml
968+
969+
# config/packages/framework.yaml
970+
framework:
971+
session:
972+
enabled: true
973+
974+
.. code-block:: xml
975+
976+
<!-- config/packages/framework.xml -->
977+
<?xml version="1.0" encoding="UTF-8" ?>
978+
<container xmlns="http://symfony.com/schema/dic/services"
979+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
980+
xmlns:framework="http://symfony.com/schema/dic/symfony"
981+
xsi:schemaLocation="http://symfony.com/schema/dic/services
982+
http://symfony.com/schema/dic/services/services-1.0.xsd
983+
http://symfony.com/schema/dic/symfony http://symfony.com/schema/dic/symfony/symfony-1.0.xsd">
984+
985+
<framework:config>
986+
<framework:session enabled="true" />
987+
</framework:config>
988+
</container>
989+
990+
.. code-block:: php
991+
992+
// config/packages/framework.php
993+
$container->loadFromExtension('framework', array(
994+
'session' => array(
995+
'enabled' => true,
996+
),
997+
));
998+
955999
assets
9561000
~~~~~~
9571001

0 commit comments

Comments
 (0)