Skip to content

Commit 6cdf34f

Browse files
javiereguiluzJean-Beru
authored andcommitted
minor symfony#16792 [Doctrine] Added naming_strategy option to doctrine config reference (naitsirch)
This PR was merged into the 4.4 branch. Discussion ---------- [Doctrine] Added naming_strategy option to doctrine config reference The `namong_strategy` option of the doctrine bundle reference is currenty missing. So I have added it together with its default value. You can compare it to the complete reference of the DoctrineBundle [here](https://github.com/doctrine/DoctrineBundle/blob/2.6.x/Resources/doc/configuration.rst). Commits ------- 99269ac Added naming_strategy option to doctrine config reference
2 parents bd0ad98 + 99269ac commit 6cdf34f

File tree

2 files changed

+14
-5
lines changed

2 files changed

+14
-5
lines changed

reference/configuration/doctrine.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -182,6 +182,7 @@ that the ORM resolves to:
182182
metadata_cache_driver: array
183183
query_cache_driver: array
184184
result_cache_driver: array
185+
naming_strategy: doctrine.orm.naming_strategy.default
185186
186187
There are lots of other configuration options that you can use to overwrite
187188
certain classes, but those are for very advanced use-cases only.
@@ -207,6 +208,7 @@ can be placed directly under ``doctrine.orm`` config level.
207208
class_metadata_factory_name: Doctrine\ORM\Mapping\ClassMetadataFactory
208209
default_repository_class: Doctrine\ORM\EntityRepository
209210
auto_mapping: false
211+
naming_strategy: doctrine.orm.naming_strategy.default
210212
hydrators:
211213
# ...
212214
mappings:

reference/configuration/framework.rst

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -337,6 +337,13 @@ settings is configured.
337337

338338
.. _reference-framework-csrf-protection:
339339

340+
field_name
341+
..........
342+
343+
**type**: ``string`` **default**: ``_token``
344+
345+
This is the field name that you should give to the CSRF token field of your form.
346+
340347
csrf_protection
341348
~~~~~~~~~~~~~~~
342349

@@ -357,14 +364,14 @@ can also :ref:`disable CSRF protection on individual forms <form-csrf-customizat
357364
.. configuration-block::
358365

359366
.. code-block:: yaml
360-
367+
361368
# config/packages/framework.yaml
362369
framework:
363370
# ...
364371
csrf_protection: true
365-
372+
366373
.. code-block:: xml
367-
374+
368375
<!-- config/packages/framework.xml -->
369376
<?xml version="1.0" encoding="UTF-8" ?>
370377
<container xmlns="http://symfony.com/schema/dic/services"
@@ -378,9 +385,9 @@ can also :ref:`disable CSRF protection on individual forms <form-csrf-customizat
378385
<framework:csrf-protection enabled="true"/>
379386
</framework:config>
380387
</container>
381-
388+
382389
.. code-block:: php
383-
390+
384391
// config/packages/framework.php
385392
use Symfony\Config\FrameworkConfig;
386393
return static function (FrameworkConfig $framework) {

0 commit comments

Comments
 (0)