tozi Posted January 1, 2014 Share Posted January 1, 2014 (edited) Hi all, i need hook modul in right column.How to do it? public function install() { return (parent::install() && Configuration::updateValue('blockcontactright_company', Configuration::get('PS_SHOP_NAME')) && Configuration::updateValue('blockcontactright_address', '') && Configuration::updateValue('blockcontactright_phone', '') && Configuration::updateValue('blockcontactright_email', Configuration::get('PS_SHOP_EMAIL')) && $this->registerHook('footer') && $this->registerHook('rightcolumn')); } I have a copy of modul blockcontactinfo blockcontactright.zip Edited January 2, 2014 by vekia (see edit history) Link to comment Share on other sites More sharing options...
tozi Posted January 1, 2014 Author Share Posted January 1, 2014 (edited) Nobody can help? Not shown http://simplydesign.sk/shop/index.php?id_cms=10&controller=cms Edited January 1, 2014 by tozi (see edit history) Link to comment Share on other sites More sharing options...
vekia Posted January 1, 2014 Share Posted January 1, 2014 your module must have a function: public functiok hookdisplayrightcolumn($params){ } it hasn't got, so it doesn't work in right column Link to comment Share on other sites More sharing options...
tozi Posted January 1, 2014 Author Share Posted January 1, 2014 (edited) Thanks. I put it before public function install() { return (parent::install() But modul not shown. public function hookdisplayrightcolumn($params){ return; } Edited January 1, 2014 by tozi (see edit history) Link to comment Share on other sites More sharing options...
vekia Posted January 1, 2014 Share Posted January 1, 2014 you have to include tpl file to display contents in your front office. without template file you will not see it. function hookrightColumn($params){ return $this->display(__FILE__, 'html.tpl'); } then create html.tpl file with your code to display in right column Link to comment Share on other sites More sharing options...
tozi Posted January 1, 2014 Author Share Posted January 1, 2014 Super it is displayed. But lacks content. You can look at the files to see if there have something wrong? Link to comment Share on other sites More sharing options...
vekia Posted January 1, 2014 Share Posted January 1, 2014 but i don;t know what you want to display there. you have to create own contents to display - in this case everything depends on you. Link to comment Share on other sites More sharing options...
tozi Posted January 1, 2014 Author Share Posted January 1, 2014 (edited) It is duplicate of modul blockcontactinfo. So I need to show the contents of this module. this? && Configuration::updateValue('blockcontactright_company', Configuration::get('PS_SHOP_NAME')) && Configuration::updateValue('blockcontactright_address', '') && Configuration::updateValue('blockcontactright_phone', '') && Configuration::updateValue('blockcontactright_email', Configuration::get('PS_SHOP_EMAIL')) But I do not know how to insert it there. Edited January 1, 2014 by tozi (see edit history) Link to comment Share on other sites More sharing options...
tozi Posted January 1, 2014 Author Share Posted January 1, 2014 So i found it. if (!$this->isCached('blockcontactright.tpl', $this->getCacheId())) $this->smarty->assign(array( 'blockcontactright_company' => Configuration::get('blockcontactright_company'), 'blockcontactright_address' => Configuration::get('blockcontactright_address'), 'blockcontactright_phone' => Configuration::get('blockcontactright_phone'), 'blockcontactright_email' => Configuration::get('blockcontactright_email') )); Link to comment Share on other sites More sharing options...
vekia Posted January 2, 2014 Share Posted January 2, 2014 exactly btw you can use this: public function hookrightcolumn($params){ return $this->hookFooter($params); } anyway, glad to hear that it works for you. im going to mark whole topic as [solved] with regards, Milos 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