Skip to content

Commit 25a17fe

Browse files
committed
feature #4264 [#4003] A few more form_themes config changes (weaverryan)
This PR was merged into the master branch. Discussion ---------- [#4003] A few more form_themes config changes | Q | A | ------------- | --- | Doc fix? | #4003 | New docs? | not, but finishing an earlier change | Applies to | >= 2.6 | Fixed tickets | - Hi guys! This follows #4003 - I think I found a few other spots that needed to be updated. Thanks! Commits ------- 695cb20 [#4003] A few more form_themes config changes
2 parents 5b65654 + 695cb20 commit 25a17fe

File tree

2 files changed

+10
-20
lines changed

2 files changed

+10
-20
lines changed

book/forms.rst

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1580,9 +1580,8 @@ file:
15801580
15811581
# app/config/config.yml
15821582
twig:
1583-
form:
1584-
resources:
1585-
- 'AcmeTaskBundle:Form:fields.html.twig'
1583+
form_themes:
1584+
- 'AcmeTaskBundle:Form:fields.html.twig'
15861585
# ...
15871586
15881587
.. code-block:: xml
@@ -1596,9 +1595,7 @@ file:
15961595
http://symfony.com/schema/dic/twig http://symfony.com/schema/dic/twig/twig-1.0.xsd">
15971596
15981597
<twig:config>
1599-
<twig:form>
1600-
<twig:resource>AcmeTaskBundle:Form:fields.html.twig</twig:resource>
1601-
</twig:form>
1598+
<twig:theme>AcmeTaskBundle:Form:fields.html.twig</twig:theme>
16021599
<!-- ... -->
16031600
</twig:config>
16041601
</container>
@@ -1607,10 +1604,8 @@ file:
16071604
16081605
// app/config/config.php
16091606
$container->loadFromExtension('twig', array(
1610-
'form' => array(
1611-
'resources' => array(
1612-
'AcmeTaskBundle:Form:fields.html.twig',
1613-
),
1607+
'form_themes' => array(
1608+
'AcmeTaskBundle:Form:fields.html.twig',
16141609
),
16151610
// ...
16161611
));

cookbook/form/create_custom_field_type.rst

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -159,27 +159,22 @@ link for details), create a ``gender_widget`` block to handle this:
159159
160160
# app/config/config.yml
161161
twig:
162-
form:
163-
resources:
164-
- 'AcmeDemoBundle:Form:fields.html.twig'
162+
form_themes:
163+
- 'AcmeDemoBundle:Form:fields.html.twig'
165164
166165
.. code-block:: xml
167166
168167
<!-- app/config/config.xml -->
169168
<twig:config>
170-
<twig:form>
171-
<twig:resource>AcmeDemoBundle:Form:fields.html.twig</twig:resource>
172-
</twig:form>
169+
<twig:form-theme>AcmeDemoBundle:Form:fields.html.twig</twig:form-theme>
173170
</twig:config>
174171
175172
.. code-block:: php
176173
177174
// app/config/config.php
178175
$container->loadFromExtension('twig', array(
179-
'form' => array(
180-
'resources' => array(
181-
'AcmeDemoBundle:Form:fields.html.twig',
182-
),
176+
'form_themes' => array(
177+
'AcmeDemoBundle:Form:fields.html.twig',
183178
),
184179
));
185180

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy