Answer the question
In order to leave comments, you need to log in
Symfony 2: How to display twig template and its variables?
The task is to edit twig templates for mailing letters in the admin panel, the usual render outputs without {{ title }} such elements, there may be some elegant solution than stupidly taking the property of the object.
so far, except as a substitute for lexer, I have not found
$lexer = new \Twig_Lexer($twig, array(
'tag_comment' => array('[#', '#]'),
'tag_block' => array('[%', '%]'),
'tag_variable' => array(''),
'interpolation' => array('#[', ']'),
));
$twig->setLexer($lexer);
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question