Hi!
According to Content representations: Representation controllers, representation templates without an existing template representation controller (say home.exhibitor.php
), should use the corresponding representation controller of site (say site.exhibitor.php
).
So, why do these controllers…
# controllers/site.exhibitor.php
return function($kirby, $pages, $page) {
return [
'controller' => 'site.exhibitor.php'
];
};
# controllers/site.php
return function($kirby, $pages, $page) {
return [
'controller' => 'site.php'
];
};
…make this template…
# templates/home.exhibitor.php
<?= $controller ?>
…echo: site.php
??? (when site.exhibitor.php
is expected)
Just in case, I tried controllers/default.php
and controllers/default.exhibitor.php
but that return and error saying $controller
doesn’t exist.
Thanks!