zsigmondszilveszter Posted November 18, 2015 Share Posted November 18, 2015 (edited) Hi, I am a presta newbie and I have the following question. I have already asked this in an existent topic, but am afraid of everybody think that is an answer. Is this the proper way to display something under a back-office modul. I have already tried the hookdisplaySomething method too. So I created a custom module with custom controller, then under Administration->Menus I created a new admin menu with the new module and controller. After that I created a test template file under "modules/szilveszterfirst/views/templates/admin/szilveszter_first/helpers/view/test.tpl". Everything works fine, except the renderView function, the template file is loaded(I printed out the result), but in the admin page doesn't show anything. Is there any prerequisite, that I didn't do? e.g. the template should contain something special(actually contains a few html tags for test sake)? The following question is also the same, but is not answered. http://stackoverflow.com/q/28948166/3604337 class AdminSzilveszterFirstController extends ModuleAdminController { public function __construct() { $this->lang = false; parent::__construct(); } public function initContent(){ $this-> renderView(); return parent::initContent(); } public function renderView() { $this->base_tpl_view = 'test.tpl'; //printf("<pre>%s</pre>",print_r(parent::renderView(),true)); return parent::renderView(); } } Edited November 18, 2015 by zsigmondszilveszter (see edit history) Link to comment Share on other sites More sharing options...
Solver Posted October 30, 2019 Share Posted October 30, 2019 Try rename test.tpl to view.tpl Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now