8000 Overrides the default {% include %} token parser since it loads throu… · lcf/symfony@30cf086 · GitHub
[go: up one dir, main page]

Skip to content

Commit 30cf086

Browse files
henrikbjornfabpot
henrikbjorn
authored andcommitted
Overrides the default {% include %} token parser since it loads through the right template renderer
1 parent 2a9ddee commit 30cf086

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/Symfony/Bundle/TwigBundle/Extension/HelpersExtension.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,9 @@ public function getTokenParsers()
6363

6464
// {% flash 'notice' %}
6565
new HelperTokenParser('flash', '<name>', 'templating.helper.session', 'getFlash'),
66+
67+
// {% include 'sometemplate.php' with ['something' : 'something2'] %}
68+
new HelperTokenParser('include', '<name> [with <arguments:array>]', 'templating.engine', 'render'),
6669
);
6770
}
6871

0 commit comments

Comments
 (0)
0