We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5171011 commit 40884b1Copy full SHA for 40884b1
book/translation.rst
@@ -520,15 +520,13 @@ via the ``request`` object::
520
521
$request->setLocale('en_US');
522
523
-.. index::
524
- single: Translations; Fallback and default locale
525
-
526
-It is also possible to store the locale in the session instead of on a per
527
-request basis. If you do this, each subsequent request will have this locale.
+.. tip::
528
529
-.. code-block:: php
+ Read :doc:`/cookbook/session/locale_sticky_session` to learn, how to store
+ the user's locale in the session.
530
531
- $this->get('session')->set('_locale', 'en_US');
+.. index::
+ single: Translations; Fallback and default locale
532
533
See the :ref:`book-translation-locale-url` section below about setting the
534
locale via routing.
0 commit comments