Jump to content

[solved] Display Manufacturer and supplier reference on Product page


Recommended Posts

I would like to display the manufacturer and supplier_reference under the product reference on the product page.

I have found the location of the of the product reference in the product.tpl

 

<p id="product_reference" {if isset($groups) OR !$product->reference}style="display: none;"{/if}><label for="product_reference">{l s='Reference :'} </label><span class="editable">{$product->reference|escape:'htmlall':'UTF-8'}</span></p>

 

 

 

I don't know what code to insert to obtain the results I want.

 

 

I am using ver.1.4.5.1

 

Thanks for any help.

Link to comment
Share on other sites

I have succeeded in displaying the manufacturer and supplier_reference under the product reference on the product page.

 

in product.tpl

 

 

<p id="product_reference" {if isset($groups) OR !$product->reference}style="display: none;"{/if}><label for="product_reference">{l s='Reference :'} </label><span class="editable">{$product->reference|escape:'htmlall':'UTF-8'}</span>

<p id="manufacturer_name" {if isset($groups) OR !$product->manufacturer_name}style="display: none;"{/if}><label for="manufacturer_name">{l s='Manufacturer :'} </label><span class="editable">{$product->manufacturer_name|escape:'htmlall':'UTF-8'}</span><br>

<p id="supplier_reference" {if isset($groups) OR !$product->supplier_reference}style="display: none;"{/if}><label for="manufacturer_name">{l s='Supplier Reference :'} </label><span class="editable">{$product->supplier_reference|escape:'htmlall':'UTF-8'}</span><br>

post-25118-0-11271300-1321799581_thumb.jpg

(supplier reference changed to model number in translations)

 

Now I would like supplier reference to be in the search.

 

Never Happy :(

  • Like 3
Link to comment
Share on other sites

try this code...

 

<p id="supplier_reference" {if !$product->supplier_reference}style="display: none;"{/if}><label for="manufacturer_name">{l s='Supplier Reference :'} </label><span class="editable">{$product->supplier_reference|escape:'htmlall':'UTF-8'}</span><br>

Link to comment
Share on other sites

Works great, thank you.

 

 

I have succeeded in displaying the manufacturer and supplier_reference under the product reference on the product page.

 

in product.tpl

 

 

<p id="product_reference" {if isset($groups) OR !$product->reference}style="display: none;"{/if}><label for="product_reference">{l s='Reference :'} </label><span class="editable">{$product->reference|escape:'htmlall':'UTF-8'}</span>

<p id="manufacturer_name" {if isset($groups) OR !$product->manufacturer_name}style="display: none;"{/if}><label for="manufacturer_name">{l s='Manufacturer :'} </label><span class="editable">{$product->manufacturer_name|escape:'htmlall':'UTF-8'}</span><br>

<p id="supplier_reference" {if isset($groups) OR !$product->supplier_reference}style="display: none;"{/if}><label for="manufacturer_name">{l s='Supplier Reference :'} </label><span class="editable">{$product->supplier_reference|escape:'htmlall':'UTF-8'}</span><br>

post-25118-0-11271300-1321799581_thumb.jpg

(supplier reference changed to model number in translations)

 

Now I would like supplier reference to be in the search.

 

Never Happy :(

Link to comment
Share on other sites

  • 1 month later...
  • 2 weeks later...
  • 2 weeks later...
  • 2 months later...
  • 3 weeks later...

Maybe it will help anybody. But only this worked for me:

 

<p class="product_name">{$product->name|escape:'htmlall':'UTF-8'}</p><br/> 
<span id="product_supplier">Supplier: {$product->supplier_name|escape:'htmlall':'UTF-8'}</span><br/>
<span id="product_manufacturer"><a href="{$link->getmanufacturerLink($product->id_manufacturer, $product->link_rewrite)}" title="{l s='more...'}">{$product->manufacturer_name|escape:'htmlall':'UTF-8'}</a></span>

  • Like 2
  • Thanks 1
Link to comment
Share on other sites

  • 2 months later...
  • 3 weeks later...

Salve dear community, I am using PS1.4.8.2,

please help me display the manufacturer in the product page.

I have tried the above provided codes, none works for me :(

Thank you for your advice

 

Add following line to products.tpl

 

 

<p id="manufacturer_name" {if !$product->manufacturer_name}style="display: none;"{/if}><label for="manufacturer_name">{l s='Manufacturer :'} </label> <span class="editable">{$product->manufacturer_name|escape:'htmlall':'UTF-8'}</span></p>

 

This will also show manufacturer when using combinations.

  • Like 1
Link to comment
Share on other sites

  • 2 months later...
  • 2 months later...

hello...

 

If i whant to ad a picture for the manufacturer in the product.tpl how can i do that...

 

I have try this :

<img src="{$img_manu_dir}{$product.id_manufacturer}-small.jpg" alt="{$product.manufacturer_name}" title="{$product.manufacturer_name}" />

 

It whant work...

 

Please help me...

Link to comment
Share on other sites

  • 3 weeks later...

@spc

 

I'm working with PS 1.5.3 and this worked fine for me:

 

<div id="headline_manufacturer_logo">
  <img src="{$img_manu_dir}{$product->id_manufacturer}.jpg" alt="{$product->manufacturer_name}" title="{$product->manufacturer_name}" />
</div>

 

Hope I could help!

Pinback

post-431255-0-37952800-1360879405_thumb.png

Link to comment
Share on other sites

  • 4 weeks later...
  • 8 months later...

Added supplier_reference to search in classes/Product.php

 

 

Sorry can you share how you did it? I need the same thing, looked around everywhere, but it's impossible to find something about it even deep googling. So The only thing i've found is your post.

 

How to add supplier_reference to search? I still use PS 1.3.7.

 

Thank You

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

  • 3 months later...
  • 7 months later...
  • 3 years later...

I would like to display the manufacturer/supplier/seller name under the product reference on the product page.

How to do that ? i'm using PrestaShop version 1.6.1.10

This is my code on product.tpl

<p id="product_reference"{if empty($product->reference) || !$product->reference} style="display: none;"{/if}>
                    <label>{l s='Reference:'} </label>
                    <span class="editable" itemprop="sku"{if !empty($product->reference) && $product->reference} content="{$product->reference}{/if}">{if !isset($groups)}{$product->reference|escape:'html':'UTF-8'}{/if}</span>
                </p>

 

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

  • 3 years later...

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...