Jump to content

List of available categories in list manufacturers.

Recommended Posts

It helps. List of available categories in list manufacturers. I have changed the code of manufacturer.tpl to:


Link to the site:http://www.tamscar-audio.es/shop/3_alphasonik


{include file="$tpl_dir./breadcrumb.tpl"}

<div id="center_column_inner" class="clearfix">

{include file="$tpl_dir./errors.tpl"}


{if !isset($errors) OR !sizeof($errors)}

<h2 class="border">{l s='List of products by manufacturer:'} 

{if isset($categories) && count($categories) == 1}

<a href="{$link->getmanufacturerLink($manufacturer->id_manufacturer, $manufacturer->link_rewrite)|escape:'htmlall':'UTF-8'}" class="colored">{$manufacturer->name|escape:'htmlall':'UTF-8'}</a> 


<span class="colored">{$manufacturer->name|escape:'htmlall':'UTF-8'}</span>



{if isset($categories)}

<!-- Categories -->

<div id="subcat">

{if count($categories) >1}

<h3>{l s='Categories'} {l s='availables'}</h3>


{foreach from=$categories item=category}


<a href="{$link->getmanufacturerLink($manufacturer->id_manufacturer, $manufacturer->link_rewrite)|escape:'htmlall':'UTF-8'}?id_category={$category.id_category}"><img src="{$link->getCatImageLink($category.link_rewrite, $category.id_image, 'medium')}" alt="" width="{$mediumSize.width}" height="{$mediumSize.height}" /></a>

<div><a href="{$link->getmanufacturerLink($manufacturer->id_manufacturer, $manufacturer->link_rewrite)|escape:'htmlall':'UTF-8'}?id_category={$category.id_category}">{$category.name|escape:'htmlall':'UTF-8'}</a></div>




{else if count($categories) ==1}

<h3>{l s='Categorie'}: {foreach from=$categories item=category}<span class="colored">{$category.name|escape:'htmlall':'UTF-8'}</span>{/foreach}</h3>



<div class="clear"></div>


<!-- /Categories -->



{if $products}

<div class="top_actions clearfix">

{include file="$tpl_dir./product-sort.tpl"}


{include file="$tpl_dir./product-list.tpl" products=$products}

{include file="$tpl_dir./pagination.tpl"}


<p>{l s='No products for this manufacturer.'}</p>






But all the categories go out and not only the available ones.


Can Alquien help me?


Thank you

Share this post

Link to post
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...

Important Information

Cookies ensure the smooth running of our services. Using these, you accept the use of cookies. Learn More