@@ -25,10 +25,10 @@ Configuration
25
25
* enabled
26
26
* field_name (deprecated)
27
27
* `form `_
28
- * enabled
28
+ * :ref: ` enabled < form-enabled >`
29
29
* csrf_protection
30
- * enabled
31
- * field_name
30
+ * :ref: ` enabled < csrf-protection-enabled >`
31
+ * ` field_name `_
32
32
* `session `_
33
33
* `name `_
34
34
* `cookie_lifetime `_
@@ -57,6 +57,7 @@ Configuration
57
57
* `magic_call `_
58
58
* `throw_exception_on_invalid_index `_
59
59
* `validation `_
60
+ * :ref: `enabled <validation-enabled >`
60
61
* `cache `_
61
62
* `enable_annotations `_
62
63
* `translation_domain `_
@@ -217,9 +218,40 @@ see :doc:`/cookbook/request/load_balancer_reverse_proxy`.
217
218
form
218
219
~~~~
219
220
221
+ .. _form-enabled :
222
+
223
+ enabled
224
+ .......
225
+
226
+ **type **: ``boolean `` **default **: ``false ``
227
+
228
+ Whether or not to enable support for the Form component.
229
+
230
+ You will also have to disable form support if you want to
231
+ :ref: `disable the validation support <validation-enabled >`.
232
+
220
233
csrf_protection
221
234
~~~~~~~~~~~~~~~
222
235
236
+ .. _csrf-protection-enabled :
237
+
238
+ enabled
239
+ .......
240
+
241
+ **type **: ``boolean `` **default **: ``true `` if form support is enabled, ``false ``
242
+ otherwise
243
+
244
+ This option can be used to disable CSRF protection of forms. You need to
245
+ disable CSRF protection to be able to disable session. For example, this
246
+ is useful when you only use forms in an API-only website.
247
+
248
+ field_name
249
+ ..........
250
+
251
+ **type **: ``string `` **default **: ``"_token" ``
252
+
253
+ The name of the hidden field used to render the :ref: `CSRF token <forms-csrf >`.
254
+
223
255
session
224
256
~~~~~~~
225
257
@@ -586,6 +618,16 @@ try to access an invalid index of an array.
586
618
validation
587
619
~~~~~~~~~~
588
620
621
+ .. _validation-enabled :
622
+
623
+ enabled
624
+ .......
625
+
626
+ **type **: ``boolean `` **default **: ``true `` if :ref: `form support is enabled <form-enabled >`,
627
+ ``false `` otherwise
628
+
629
+ Whether or not to enable validation support.
630
+
589
631
cache
590
632
.....
591
633
0 commit comments