Symfony configure Twig template for hinclude -
i trying obey http://symfony.com/doc/current/book/templating.html#asynchronous-content-with-hinclude-js setting hinclude don't contents of hinclude.html.twig, instead "::hinclude.html.twig" displayed.
in /app/config/config.yml have:
templating: engines: ['twig'] hinclude_default_template: "::hinclude.html.twig" hinclude.html.twig resides in /app/ressources/views/default/hinclude.html.twig , nothing more than:
loading.... the actual content loaded correctly hinclude.js instead of displaying loading... displays template path in config file: ::hinclude.twig.html
also these configurations not work:
hinclude_default_template: ::hinclude.html.twig hinclude_default_template: "hinclude.html.twig" hinclude_default_template: hinclude.html.twig how can use twig template?
thanks!
it figured out misconfiguration...
this doesn't work:
hinclude_default_template: "::hinclude.html.twig" hinclude_default_template: ":default:hinclude.html.twig" this work:
hinclude_default_template: ":default:hinclude.html.twig" you need use lower case "default".
Comments
Post a Comment