Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit110ce4d

Browse files
authored
Clarifying LocaleSwitcher's behavior
1 parent88a7eb2 commit110ce4d

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

‎translation.rst

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1104,6 +1104,13 @@ just to run some code. Imagine a console command that renders Twig templates
11041104
of emails in different languages. You need to change the locale only to
11051105
render those templates.
11061106

1107+
..note::
1108+
1109+
The LocaleSwitcher will apply the locale at a request level
1110+
this means that it will be available only for that request. A
1111+
redirect, for example, will cancel the LocaleSwitcher's effect.
1112+
For a permanent locale switch between requests see https://symfony.com/doc/current/session.html#making-the-locale-sticky-during-a-user-s-session.
1113+
11071114
The ``LocaleSwitcher`` class allows you to change at once the locale
11081115
of:
11091116

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp