Skip to content

Commit 3b7e398

Browse files
ip512weaverryan
authored andcommitted
Add something about clear the cache when template is added
1 parent a042591 commit 3b7e398

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

book/templating.rst

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1012,6 +1012,11 @@ from the bundle to ``app/Resources/AcmeBlogBundle/views/Blog/index.html.twig``
10121012
(the ``app/Resources/AcmeBlogBundle`` directory won't exist, so you'll need
10131013
to create it). You're now free to customize the template.
10141014

1015+
When Symfony looks into folders to discover templates, the location of the
1016+
found template is cached. If you add a template in a new location, don't
1017+
forget to clear the cache (``./app/console cache:clear``), even if you are in
1018+
debug mode.
1019+
10151020
This logic also applies to base bundle templates. Suppose also that each
10161021
template in ``AcmeBlogBundle`` inherits from a base template called
10171022
``AcmeBlogBundle::layout.html.twig``. Just as before, Symfony2 will look in

0 commit comments

Comments
 (0)