Skip to content

Commit 8e825d9

Browse files
committed
Documented the overridden options of the "password" type
1 parent 618e11d commit 8e825d9

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

reference/forms/types/password.rst

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@ The ``password`` field renders an input password text box.
99
+-------------+------------------------------------------------------------------------+
1010
| Rendered as | ``input`` ``password`` field |
1111
+-------------+------------------------------------------------------------------------+
12+
| Overridden | - `trim`_ |
13+
| Options | |
14+
+-------------+------------------------------------------------------------------------+
1215
| Options | - `always_empty`_ |
1316
+-------------+------------------------------------------------------------------------+
1417
| Inherited | - `disabled`_ |
@@ -28,6 +31,19 @@ The ``password`` field renders an input password text box.
2831
| Class | :class:`Symfony\\Component\\Form\\Extension\\Core\\Type\\PasswordType` |
2932
+-------------+------------------------------------------------------------------------+
3033

34+
Overridden Options
35+
------------------
36+
37+
trim
38+
~~~~
39+
40+
**default**: ``false``
41+
42+
Unlike the rest of form types, the ``password`` type doesn't apply the
43+
phpfunction:`trim` function to the value submitted by the user. This ensures that
44+
the password is merged back onto the underlying object exactly as it was typed
45+
by the user.
46+
3147
Field Options
3248
-------------
3349

0 commit comments

Comments
 (0)