Jump to content

Different product-list template blocklayered search


facky75

Recommended Posts

Hello everyone,

 

I'm trying to make different product-list template depending on the category.

Everything works fine exept when I search with blocklayered it shows my default product list.

 

I've found the part of the code which manage that in /modules/blocklayered/blocklayered.php :

 
if ($nb_products == 0)
$product_list = $this->display(__FILE__, 'blocklayered-no-products.tpl');
else
$product_list = $smarty->fetch(_PS_THEME_DIR_.'product-list.tpl');
 
And I tried to do that:
if ($nb_products == 0)
$product_list = $this->display(__FILE__, 'blocklayered-no-products.tpl');
elseif ( $category->id> == 16)
$product_list = $smarty->fetch(_PS_THEME_DIR_.'product-list16.tpl');
else
$product_list = $smarty->fetch(_PS_THEME_DIR_.'product-list.tpl');

 

But it's not working :(

I would be very grateful if someone could help me

 

PS: I'm on prestashop 1.5

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...