Permalink
Browse files

minor #4399 Explain form() and form_widget() in form customization (o…

…opsFrogs, WouterJ)

This PR was merged into the 2.3 branch.

Discussion
----------

Explain form() and form_widget() in form customization

Continues #4365

| Q   | A
| --- | ---
| Doc fix? | yes
| New docs? | no
| Applies to | all
| Fixed tickets | -

Original PR description:

> In the Form chapter of Book for Symfony 2.3, we use `{{ form(form) }}` to render the entire form ( in contrast to `{{ form_widget(form) }}` for older version of Symfony ). so maybe it should use `{{ form(form) }}` here for consistency.

Commits
-------

0086c5e Applied suggestion by Ryan
d653ff4 Update form_customization.rst
  • Loading branch information...
weaverryan committed Nov 20, 2014
2 parents 2139754 + 0086c5e commit c008733b9ee8d7e12507ab2cf813d03808b49ab5
Showing with 9 additions and 1 deletion.
  1. +9 −1 cookbook/form/form_customization.rst
@@ -67,11 +67,19 @@ just one line:
.. code-block:: jinja
{# renders all fields #}
{{ form_widget(form) }}
{# renders all fields *and* the form start and end tags #}
{{ form(form) }}
.. code-block:: php
<?php echo $view['form']->widget($form); ?>
<!-- renders all fields -->
<?php echo $view['form']->widget($form) ?>
<!-- renders all fields *and* the form start and end tags -->
<?php echo $view['form']->form($form) ?>
The remainder of this recipe will explain how every part of the form's markup
can be modified at several different levels. For more information about form

0 comments on commit c008733

Please sign in to comment.