-
-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Added a note about customizing a form with more than one template #3875
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
Added a note about customizing a form with more than one template #3875
Conversation
Q | A |
---|---|
Doc fix? | no |
New docs? | yes |
Applies to | 2.3+ |
Fixed tickets | #3643 |
@@ -298,6 +298,33 @@ When the ``form.age`` widget is rendered, Symfony will use the ``integer_widget` | |||
block from the new template and the ``input`` tag will be wrapped in the | |||
``div`` element specified in the customized block. | |||
|
|||
Multiple templates |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Multiple Templates
This makes sense, but to be difficult, is there value in showing both ways? Should we pick just one of the ways and show it? Disagree? |
What do you mean with both ways, @weaverryan? A single file vs. multiple files? |
I mean showing: {% form_theme form '::common.html.twig' ':Form:fields.html.twig' %} AND {% form_theme form with ['::common.html.twig', ':Form:fields.html.twig'] %} I think we should just pick one of these formats and not show the other one. I don't believe there is a difference between the 2 functionally. |
The |
my suggestion is to document the |
I agree with Stof. @javiereguiluz if you agree, can we just show the |
@stof @weaverryan thanks for your suggestions! I've just removed the old syntax explanation. |
Multiple Templates | ||
.................. | ||
|
||
A form can also be customized applying several templates. To do so, pass the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
... form can also be customized by applying several templates. To do this, pass
Multiple Templates | ||
.................. | ||
|
||
A form can also be customized applying several templates. To do this, pass the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
... can also be customized by applying several templates...
@weaverryan excuse me for taking so long to fix the error that you reported. I think that now everything is OK to merge it. |
It's cool - we've been busy :). Thanks for this! |
…e template (javiereguiluz) This PR was merged into the 2.3 branch. Discussion ---------- Added a note about customizing a form with more than one template | Q | A | ------------- | --- | Doc fix? | no | New docs? | yes | Applies to | 2.3+ | Fixed tickets | #3643 Commits ------- ce14104 Fixed a minor grammar mistake 1b386ff Fixed a minor error 08d26ee Removed the old syntax and left just the "with" keyword syntax 94625c5 Fixed minor formatting issue 6621720 Minor formatting improvement 2b0213b Added a note about customizing a form with more than one template