prestashop add variables to view

Solutions on MaxInterview for prestashop add variables to view by the best coders in the world

showing results for - "prestashop add variables to view"
Giacomo
14 Nov 2018
1<?php
2    public function hookDisplayLeftColumn($params)
3    {
4        $this->context->smarty->assign([
5            'my_module_name' => Configuration::get('MYMODULE_NAME'),
6           
7        ]);
8
9        return $this->display(__FILE__, 'mymodule.tpl');
10    }
11
12    ?>
13 
14<!-- Inside smarty or twig file -->
15     {if isset($my_module_name) && $my_module_name}
16          {$my_module_name}
17     {else}
18           World
19     {/if}