8000 [#6143] some tweaks · symfony/symfony-docs@d46b458 · GitHub
[go: up one dir, main page]

Skip to content

Commit d46b458

Browse files
committed
[#6143] some tweaks
1 parent 794c1ee commit d46b458

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

cookbook/security/form_login_setup.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ First, enable form login under your firewall:
4242
<config>
4343
<firewall name="main">
4444
<anonymous />
45-
<form-login login-path="/login" check-path="/login" />
45+
<form-login login-path="login" check-path="login" />
4646
</firewall>
4747
</config>
4848
</srv:container>
@@ -82,8 +82,8 @@ bundle::
8282
{
8383
}
8484

85-
Next, create a route for the path you configured earlier
86-
under your ``form_login`` configuration (``/login``):
85+
Next, configure the route that you earlier used under your ``form_login``
86+
configuration (``login``):
8787

8888
.. configuration-block::
8989

@@ -247,7 +247,7 @@ Finally, create the template:
247247

248248
The form can look like anything, but has a few requirements:
249249

250-
* The form must POST to ``/login``, since that's what you configured
250+
* The form must POST to the ``login`` route, since that's what you configured
251251
under the ``form_login`` key in ``security.yml``.
252252

253253
* The username must have the name ``_username`` and the password must have

reference/configuration/security.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -129,10 +129,10 @@ Each part will be explained in the next section.
129129
provider: some_key_from_above
130130
form_login:
131131
# submit the login form here
132-
check_path: login
132+
check_path: /login_check
133133
134134
# the user is redirected here when they need to log in
135-
login_path: login
135+
login_path: /login
136136
137137
# if true, forward the user to the login form instead of redirecting
138138
use_forward: false
@@ -252,7 +252,7 @@ The Login Form and Process
252252
login_path
253253
..........
254254

255-
**type**: ``string`` **default**: ``login``
255+
**type**: ``string`` **default**: ``/login``
256256

257257
This is the route or path that the user will be redirected to (unless ``use_forward``
258258
is set to ``true``) when they try to access a protected resource but isn't
@@ -265,7 +265,7 @@ you may create a redirect loop. For details, see
265265
check_path
266266
..........
267267

268-
**type**: ``string`` **default**: ``login``
268+
**type**: ``string`` **default**: ``/login_check``
269269

270270
This is the route or path that your login form must submit to. The firewall
271271
will intercept any requests (``POST`` requests only, by default) to this

0 commit comments

Comments
 (0)
0