You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Given two twig templates with identical names, one stored in app/resource/ and the other in app/htdocs/content/themes//views/, the one inside app takes precedence over the one inside themes.
Repeating this setup with php templates, the one inside themes takes precedence over the one inside app, which is expected behavior.
Steps to reproduce
Create two twig templates test-twig.twig with identical names and place one inside the app template directory and the other one inside the theme's template directory:
app/resource/test-twig.twig
app/htdocs/content/themes//views/test-twig.twig
Repeat this setup with two php templates test-php.php:
app/resource/test-php.php
app/htdocs/content/themes//views/test-php.php
Create two according routes for rendering the twig and php templates in app/routes/web.php:
Description
Given two twig templates with identical names, one stored in app/resource/ and the other in app/htdocs/content/themes//views/, the one inside app takes precedence over the one inside themes.
Repeating this setup with php templates, the one inside themes takes precedence over the one inside app, which is expected behavior.
Steps to reproduce
Create two twig templates test-twig.twig with identical names and place one inside the app template directory and the other one inside the theme's template directory:
Repeat this setup with two php templates test-php.php:
Create two according routes for rendering the twig and php templates in app/routes/web.php:
Open both web pages localhost/test-twig and localhost/test-php to see that the app's twig template and the theme's php template are rendered.
Expected behavior
The theme's twig template should take precedence over the app one.
The text was updated successfully, but these errors were encountered: