Skip to content

Commit 240f639

Browse files
committed
minor symfony#6735 Change _method parameter versionadded note (sfdumi, WouterJ)
This PR was merged into the 2.7 branch. Discussion ---------- Change _method parameter versionadded note Replaces symfony#6221 Commits ------- 567ef6a Change note, as 2.7 doesn't document 2.2 changes. ef556a8 Minor update to Symfony version for method override
2 parents 315cd5b + 567ef6a commit 240f639

File tree

1 file changed

+5
-8
lines changed

1 file changed

+5
-8
lines changed

cookbook/routing/method_parameters.rst

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -74,14 +74,6 @@ delete it by matching on GET, PUT and DELETE.
7474
Faking the Method with ``_method``
7575
----------------------------------
7676

77-
.. note::
78-
79-
The ``_method`` functionality shown here is disabled by default in Symfony 2.2
80-
and enabled by default in Symfony 2.3. To control it in Symfony 2.2, you
81-
must call :method:`Request::enableHttpMethodParameterOverride <Symfony\\Component\\HttpFoundation\\Request::enableHttpMethodParameterOverride>`
82-
before you handle the request (e.g. in your front controller). In Symfony
83-
2.3, use the :ref:`configuration-framework-http_method_override` option.
84-
8577
Unfortunately, life isn't quite this simple, since most browsers do not support
8678
sending PUT and DELETE requests via the `method` attribute in an HTML form. Fortunately,
8779
Symfony provides you with a simple way of working around this limitation. By including
@@ -90,3 +82,8 @@ will use this as the method when matching routes. Forms automatically include a
9082
hidden field for this parameter if their submission method is not GET or POST.
9183
See :ref:`the related chapter in the forms documentation<book-forms-changing-action-and-method>`
9284
for more information.
85+
86+
.. tip::
87+
88+
You can disable the ``_method`` functionality shown here using the
89+
:ref:`configuration-framework-http_method_override` option.

0 commit comments

Comments
 (0)