Send data to default.twig in the default theme?
Created 7 years ago by mohammed_abdallahi want to send array to the default page to the theme where the controller that's i can compact my data ??? plz help
mohammed_abdallah
—
7 years ago
i know this way but where i put this line ??
mohammed_abdallah
—
7 years ago
u got me ? i can't find the controller that's render the default view ?
ryanthompson
—
7 years ago
Can you use variables or something to control this? Otherwise you can make a plugin class inside your theme and add some constants or functions to help you out there.
https://pyrocms.com/help/addon-development/plugins
You can also add a FooThemePlugin
class next to your FooTheme
class and it'll be picked up automatically.
that's more like a laravel question but you can try:
somewhere in you code, and then use it in twig file: {{ variable }}