File tree 1 file changed +3
-9
lines changed
1 file changed +3
-9
lines changed Original file line number Diff line number Diff line change @@ -15,9 +15,7 @@ Building Forms
15
15
The Form component allows you to build forms right inside your controller
16
16
code. Honestly, unless you need to reuse the form somewhere else, that's
17
17
totally fine. But for organize and reuse, we recommend that you define each
18
- form in its own PHP class:
19
-
20
- .. code-block :: php
18
+ form in its own PHP class::
21
19
22
20
namespace AppBundle\Form;
23
21
@@ -51,9 +49,7 @@ form in its own PHP class:
51
49
}
52
50
}
53
51
54
- To use the class, use ``createForm `` and instantiate the new class:
55
-
56
- .. code-block :: php
52
+ To use the class, use ``createForm `` and instantiate the new class::
57
53
58
54
use AppBundle\Form\PostType;
59
55
// ...
@@ -108,9 +104,7 @@ directly in your form class, this would effectively limit the scope of that form
108
104
109
105
This form *may * have been designed for creating posts, but if you wanted
110
106
to reuse it for editing posts, the button label would be wrong. Instead,
111
- some developers configure form buttons in the controller:
112
-
113
- .. code-block :: php
107
+ some developers configure form buttons in the controller::
114
108
115
109
namespace AppBundle\Controller\Admin;
116
110
You can’t perform that action at this time.
0 commit comments