Jump to content

{$HOOK_RIGHT_COLUMN}


Recommended Posts

This is a hook. Some modules can add content to this. On Admin Panel you can see wich modules use this hooks.

Go to from menu Modules->Positions

and search "Right colomn blocks" and "Footer".

 

For example I have for "Right colomn blocks"

next modules by default:

1. Top Sellers Block

2. New products block

3. Specials block

4. CMS block

5. Stores block

6. Block contact

 

On wich this modules you can found function (see Technical name: displayRightContent) hookdisplayRightContent.

 

Also can be used old style hooks from this list http://doc.prestasho...+PrestaShop+1.5

 

rightColumn displayRightColumn

 

For example for module "New products block" code is here

/modules/blocknewproducts/blocknewproducts.php

 

 

 



public function hookRightColumn($params)
{
global $smarty;

$newProducts = Product::getNewProducts((int)($params['cookie']->id_lang), 0, (int)(Configuration::get('NEW_PRODUCTS_NBR')));
if (!$newProducts AND !Configuration::get('PS_BLOCK_NEWPRODUCTS_DISPLAY'))
return;
$smarty->assign(array('new_products' => $newProducts, 'mediumSize' => Image::getSize('medium')));

return $this->display(__FILE__, 'blocknewproducts.tpl');
}

 

Also you can set position of blocks from admin panel.

Edited by andik (see edit history)
Link to comment
Share on other sites

×
×
  • Create New...