Jump to content

re hook Custom Link block at Footer


Recommended Posts

Hi,

has anyone tried to rehook the custom link to the footer?

 

I tried, but it failed, once i hook it to the footer, my whole website become blank.

 

here are the code i have done on modules/blockcustomlinks/blockcustomlinks.php

 

public function hookTop($params)
{
 $links = $this->getLinks();

 $this->smarty->assign(array(
  'blocklink_links' => $links,
  'title' => Configuration::get('PS_BLOCKCUSTOMLINK_TITLE', $this->context->language->id),
  'url' => Configuration::get('PS_BLOCKCUSTOMLINK_URL'),
  'lang' => 'text_'.$this->context->language->id
 ));
 if (!$links)
  return false;
 return $this->display(__FILE__, 'blockcustomlinks.tpl');
}

public function hookHeader($params)
{
 $this->context->controller->addCSS($this->_path.'blocklink.css', 'all');
}

public function hookFooter($params)
{
 return $this->hookLeftColumn($params);
}

 

this is the code I have added in

 

public function hookFooter($params)
{
 return $this->hookLeftColumn($params);
}

Link to comment
Share on other sites

but when i change to this

public function hookFooter($params)
{
 $this->context->controller->addCSS($this->_path.'blocklink.css', 'all');
}

 

there is no error when i have hook it up, but I am unable to see my custom links!!!

Link to comment
Share on other sites

×
×
  • Create New...