How to Create Controller for PageTemplate?
Permalink
Hi,
I am facing difficulties to create controller for page template, so please share how to create controller for page template.
I am facing difficulties to create controller for page template, so please share how to create controller for page template.
We can't create controller for page template like 5.6. But We could create controller to its page type
We can create page type controller using the following method:
For example you have event_details page template . its page type handle name is event. In this case, we need to create file application\controllers\page_types\Event.php
its code will be like this