Jump to content

Front page not embed template


Recommended Posts

Hello everybody 

I am write a module and I can not embed original template

this is my code

public function initContent()
{
    parent::initContent();
    $this->setTemplate('module:mymodule/views/templates/front/display.tpl');
}

the display.tpl content is showing but not the template.

I google it and try many different way, without any result

In other module I used, without any problem, renderView instead initContent, but is admin controller.

If I try to do the same in this plugin is return me a smarty Exception: Missing '$template' parameter

I read this article: https://devdocs.prestashop.com/1.7/modules/creation/displaying-content-in-front-office/

and until 1.4 you must to use include

Someone have a solution about white page? 

Thanks in advance

Gabriele

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...