diff --git a/blocklink.php b/blocklink.php index 5bce869..d083ccf 100644 --- a/blocklink.php +++ b/blocklink.php @@ -18,9 +18,9 @@ * versions in the future. If you wish to customize PrestaShop for your * needs please refer to http://www.prestashop.com for more information. * -* @author PrestaShop SA -* @copyright 2007-2014 PrestaShop SA -* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0) +* @author PrestaShop SA +* @copyright 2007-2014 PrestaShop SA +* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0) * International Registered Trademark & Property of PrestaShop SA */ @@ -112,7 +112,7 @@ public function uninstall() return true; } - public function hookLeftColumn($params) + public function hookDisplayLeftColumn($params) { $links = $this->getLinks(); @@ -128,12 +128,28 @@ public function hookLeftColumn($params) return $this->display(__FILE__, 'blocklink.tpl'); } - public function hookRightColumn($params) + public function hookDisplayRightColumn($params) { - return $this->hookLeftColumn($params); + return $this->hookDisplayLeftColumn($params); } - public function hookHeader($params) + public function hookDisplayFooter($params) + { + $links = $this->getLinks(); + + $this->smarty->assign(array( + 'blocklink_links' => $links, + 'title' => Configuration::get('PS_BLOCKLINK_TITLE', $this->context->language->id), + 'url' => Configuration::get('PS_BLOCKLINK_URL'), + 'lang' => 'text_'.$this->context->language->id + )); + if (!$links) + return false; + + return $this->display(__FILE__, 'blocklinkfooter.tpl'); + } + + public function hookDisplayHeader($params) { $this->context->controller->addCSS($this->_path.'blocklink.css', 'all'); } diff --git a/blocklinkfooter.tpl b/blocklinkfooter.tpl new file mode 100644 index 0000000..7d27dcf --- /dev/null +++ b/blocklinkfooter.tpl @@ -0,0 +1,46 @@ +{* +* 2007-2014 PrestaShop +* +* NOTICE OF LICENSE +* +* This source file is subject to the Academic Free License (AFL 3.0) +* that is bundled with this package in the file LICENSE.txt. +* It is also available through the world-wide-web at this URL: +* http://opensource.org/licenses/afl-3.0.php +* If you did not receive a copy of the license and are unable to +* obtain it through the world-wide-web, please send an email +* to license@prestashop.com so we can send you a copy immediately. +* +* DISCLAIMER +* +* Do not edit or add to this file if you wish to upgrade PrestaShop to newer +* versions in the future. If you wish to customize PrestaShop for your +* needs please refer to http://www.prestashop.com for more information. +* +* @author PrestaShop SA +* @copyright 2007-2014 PrestaShop SA +* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*} + + + +