dhada Posted November 21, 2011 Share Posted November 21, 2011 How can i get all the manufacturers base on the current category? Thanks. I already add this code but all the manufacturers showing. CategoryController.php self::$smarty->assign(array( 'allow_oosp' => (int)(Configuration::get('PS_ORDER_OUT_OF_STOCK')), 'comparator_max_item' => (int)(Configuration::get('PS_COMPARATOR_MAX_ITEM')), 'suppliers' => Supplier::getSuppliers(), 'manufacturers' => Manufacturer::getManufacturers() )); category.tpl {if isset($manufacturers)} <div id="manufacturers"> <h3>{l s='Brands'}</h3> <ul class="inline_list"> {foreach from=$manufacturers item=manufacturer} <li> <a href="{$link->getManufacturerLink($manufacturer.id_manufacturer, $manufacturer.link_rewrite)|escape:'htmlall':'UTF-8'}" title="{$manufacturer.name|escape:'htmlall':'UTF-8'}"> {$manufacturer.name|escape:'htmlall':'UTF-8'} </a> </li> {/foreach} </ul> <br class="clear"/> </div> {/if} Link to comment Share on other sites More sharing options...
Recommended Posts