File tree Expand file tree Collapse file tree 1 file changed +5
-17
lines changed Expand file tree Collapse file tree 1 file changed +5
-17
lines changed Original file line number Diff line number Diff line change @@ -383,24 +383,12 @@ Managing the Session
383
383
--------------------
384
384
385
385
Symfony provides a session service that you can use to store information
386
- about the user between requests. Session storage and other configuration can
387
- be controlled under the :ref: ` framework.session configuration < config-framework-session >` .
386
+ about the user between requests. Session is enabled by default, but will only be
387
+ started if you read or write from it .
388
388
389
- First, activate the session by uncommenting the ``session `` key in ``config/packages/framework.yaml ``:
390
-
391
- .. code-block :: diff
392
-
393
- # config/packages/framework.yaml
394
- framework:
395
- # ...
396
-
397
- - #session:
398
- - # # The native PHP session handler will be used
399
- - # handler_id: ~
400
- + session:
401
- + # The native PHP session handler will be used
402
- + handler_id: ~
403
- # ...
389
+ Session storage and other configuration can be controlled under the
390
+ :ref: `framework.session configuration <config-framework-session >` in
391
+ ``config/packages/framework.yaml ``.
404
392
405
393
To get the session, add an argument and type-hint it with
406
394
:class: `Symfony\\ Component\\ HttpFoundation\\ Session\\ SessionInterface `::
You can’t perform that action at this time.
0 commit comments