Skip to content

Commit 21ec4fd

Browse files
committed
minor #5664 Info about implicit session start (ThomasLandauer)
This PR was submitted for the 2.7 branch but it was merged into the 2.3 branch instead (closes #5664). Discussion ---------- Info about implicit session start This should be explained *somewhere* (took me a while to figure it out). If this is not the right place (or format), please go ahead and correct it! Commits ------- 662bb01 Info about implicit session start
2 parents 87b7e3d + 662bb01 commit 21ec4fd

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

book/forms.rst

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1783,6 +1783,11 @@ The ``_token`` field is a hidden field and will be automatically rendered
17831783
if you include the ``form_end()`` function in your template, which ensures
17841784
that all un-rendered fields are output.
17851785

1786+
.. caution::
1787+
1788+
Since the token is stored in the session, a session is started automatically
1789+
as soon as you render a form with CSRF protection.
1790+
17861791
The CSRF token can be customized on a form-by-form basis. For example::
17871792

17881793
use Symfony\Component\OptionsResolver\OptionsResolverInterface;

0 commit comments

Comments
 (0)