Skip to content

Minor tweaks to form action/method #3630

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 12, 2014
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions reference/forms/types/form.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,18 @@ See :class:`Symfony\\Component\\Form\\Extension\\Core\\Type\\FormType`.
The ``form`` type predefines a couple of options that are then available
on all fields.

.. include:: /reference/forms/types/options/compound.rst.inc

.. include:: /reference/forms/types/options/data.rst.inc

.. include:: /reference/forms/types/options/data_class.rst.inc

.. include:: /reference/forms/types/options/action.rst.inc

.. include:: /reference/forms/types/options/method.rst.inc

.. include:: /reference/forms/types/options/empty_data.rst.inc

.. include:: /reference/forms/types/options/compound.rst.inc

.. include:: /reference/forms/types/options/required.rst.inc

.. include:: /reference/forms/types/options/label.rst.inc
Expand Down Expand Up @@ -62,7 +66,3 @@ on all fields.
.. include:: /reference/forms/types/options/post_max_size_message.rst.inc

.. include:: /reference/forms/types/options/pattern.rst.inc

.. include:: /reference/forms/types/options/action.rst.inc

.. include:: /reference/forms/types/options/method.rst.inc
2 changes: 1 addition & 1 deletion reference/forms/types/options/action.rst.inc
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ action

**type**: ``string`` **default**: empty string

This option specifies where to send the form's data on submission (usually an
This option specifies where to send the form's data on submission (usually a
URI). Its value is rendered as the ``action`` attribute of the ``form``
element. An empty value is considered a same-document reference, i.e. the form
will be submitted to the same URI that rendered the form.
8 changes: 5 additions & 3 deletions reference/forms/types/options/method.rst.inc
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ used to decide whether to process the form submission in the

.. note:

Only the PATCH method allows submitting partial data without that missing
fields are set to ``null`` in the underlying data (preserving default
values, if any).
The PATCH method allows submitting partial data. In other words, if the
submitted form data is missing certain fields, those will be ignored
and the default values (if any) will be used. With all other HTTP methods,
if the submitted form data is missing some fields, those fields are set
to ``null``.