Skip to content

Commit

Permalink
Ref #3903 - Forms: normalize methods list for form_start / form_error…
Browse files Browse the repository at this point in the history
… / form_end
  • Loading branch information
ternel committed Dec 21, 2014
1 parent 7054cf4 commit f88d8af
Showing 1 changed file with 12 additions and 9 deletions.
21 changes: 12 additions & 9 deletions book/forms.rst
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ from inside a controller::

Creating a form requires relatively little code because Symfony form objects
are built with a "form builder". The form builder's purpose is to allow you
to write simple form "recipes", and have it do all the heavy-lifting of actually
to write simple form "recipes", and have it do all the gvy-lifting of actually
building the form.

In this example, you've added two fields to your form - ``task`` and ``dueDate`` -
Expand Down Expand Up @@ -167,16 +167,19 @@ helper functions:

That's it! Just three lines are needed to render the complete form:

* ``form_start(form)`` - Renders the start tag of the form, including the
correct enctype attribute when using file uploads;
``form_start(form)``
Renders the start tag of the form, including the correct enctype attribute
when using file uploads.

* ``form_widget(form)`` - Renders all of the fields, which includes the field
element itself, a label and any validation error messages for the field;
``form_widget(form)``
Renders all of the fields, which includes the field element itself, a label
and any validation error messages for the field.

* ``form_end()`` - Renders the end tag of the form and any fields that have not
yet been rendered, in case you rendered each field yourself. This is useful
for rendering hidden fields and taking advantage of the automatic
:ref:`CSRF Protection <forms-csrf>`.
``form_end()``
Renders the end tag of the form and any fields that have not
yet been rendered, in case you rendered each field yourself. This is useful
for rendering hidden fields and taking advantage of the automatic
:ref:`CSRF Protection <forms-csrf>`.

.. seealso::

Expand Down

0 comments on commit f88d8af

Please sign in to comment.