Пример #1
0
 public function hookLeftColumn($params)
 {
     if (!$this->checkServerConf()) {
         return false;
     }
     $is_home = Tools::getValue('controller') == 'index' ? true : false;
     require_once _PS_MODULE_DIR_ . "psnews/psnews.php";
     require_once _PS_MODULE_DIR_ . "psnews/classes/News.php";
     $pref = array_merge(Psnews::getPreferences(), self::getPreferences());
     if (!($is_home && $pref['news_articles_home'] == 1)) {
         $this->calculHookCommon($params);
         return $this->display(__FILE__, 'news.tpl');
     }
 }
Пример #2
0
 public function __construct()
 {
     parent::__construct();
     $this->context = Context::getContext();
     $this->conf = Psnews::getPreferences();
 }