@@ -138,6 +138,7 @@ Configuration
138
138
139
139
* `session `_
140
140
141
+ * `cache_limiter `_
141
142
* `cookie_domain `_
142
143
* `cookie_httponly `_
143
144
* `cookie_lifetime `_
@@ -832,6 +833,50 @@ cookie_path
832
833
This determines the path to set in the session cookie. By default, it will
833
834
use ``/ ``.
834
835
836
+ cache_limiter
837
+ .............
838
+
839
+ **type **: ``string `` or ``int `` **default **: ``'' ``
840
+
841
+ If set to ``0 ``, Symfony won't set any particular header related to the cache
842
+ and it will rely on the cache control method configured in the
843
+ `session.cache-limiter `_ PHP.ini option.
844
+
845
+ Unlike the other session options, ``cache_limiter `` is set as a regular
846
+ :doc: `container parameter </service_container/parameters >`:
847
+
848
+ .. configuration-block ::
849
+
850
+ .. code-block :: yaml
851
+
852
+ # app/config/services.yml
853
+ parameters :
854
+ session.storage.options :
855
+ cache_limiter : 0
856
+
857
+ .. code-block :: xml
858
+
859
+ <!-- app/config/services.xml -->
860
+ <?xml version =" 1.0" encoding =" UTF-8" ?>
861
+ <container xmlns =" http://symfony.com/schema/dic/services"
862
+ xmlns : xsi =" http://www.w3.org/2001/XMLSchema-instance"
863
+ xsi : schemaLocation =" http://symfony.com/schema/dic/services
864
+ https://symfony.com/schema/dic/services/services-1.0.xsd" >
865
+
866
+ <parameters >
867
+ <parameter key =" session.storage.options" type =" collection" >
868
+ <parameter key =" cache_limiter" >0</parameter >
869
+ </parameter >
870
+ </parameters >
871
+ </container >
872
+
873
+ .. code-block :: php
874
+
875
+ // app/config/services.php
876
+ $container->setParameter('session.storage.options', [
877
+ 'cache_limiter' => 0,
878
+ ]);
879
+
835
880
cookie_domain
836
881
.............
837
882
@@ -2333,3 +2378,4 @@ to know their differences.
2333
2378
.. _`webpack-manifest-plugin` : https://www.npmjs.com/package/webpack-manifest-plugin
2334
2379
.. _`error_reporting PHP option` : https://secure.php.net/manual/en/errorfunc.configuration.php#ini.error-reporting
2335
2380
.. _`CSRF security attacks` : https://en.wikipedia.org/wiki/Cross-site_request_forgery
2381
+ .. _`session.cache-limiter` : https://www.php.net/manual/en/session.configuration.php#ini.session.cache-limiter
0 commit comments