Jorlb Posted April 8, 2015 Share Posted April 8, 2015 Hello all, I'm new on PrestaShop. I would like to display phone number, adress, gzip and country of the manufacturer in manufacturer.tpl Someone has the solution ? Thanks Link to comment Share on other sites More sharing options...
sandipchandela Posted April 13, 2015 Share Posted April 13, 2015 Put some code in controllers/front/ManufacturerController.php Search assignOne function around 90 line. Replace old method code with following new method code. protected function assignOne() { $this->manufacturer->description = Tools::nl2br(trim($this->manufacturer->description)); $nbProducts = $this->manufacturer->getProducts($this->manufacturer->id, null, null, null, $this->orderBy, $this->orderWay, true); $this->pagination((int)$nbProducts); $products = $this->manufacturer->getProducts($this->manufacturer->id, $this->context->language->id, (int)$this->p, (int)$this->n, $this->orderBy, $this->orderWay); $this->addColorsToProductList($products); $address = $this->manufacturer->getAddresses($this->context->language->id); $this->context->smarty->assign(array( 'nb_products' => $nbProducts, 'products' => $products, 'path' => ($this->manufacturer->active ? Tools::safeOutput($this->manufacturer->name) : ''), 'manufacturer' => $this->manufacturer, 'comparator_max_item' => Configuration::get('PS_COMPARATOR_MAX_ITEM'), 'body_classes' => array($this->php_self.'-'.$this->manufacturer->id, $this->php_self.'-'.$this->manufacturer->link_rewrite), 'address' => $address, )); } Now go to the themes\your_current_theme folder and open manufacturer.file in some notepad editor. put following code in where you want to display manufac data. {if !empty($address)} <div> {foreach $address as $add} {$add.address1} {$add.phone} {$add.city}{$add.postcode} {$add.phone_mobile} {/foreach} </div> {/if} Link to comment Share on other sites More sharing options...
PizzaPie Posted February 19, 2016 Share Posted February 19, 2016 Thankyou, I needed this :-) Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now