Jump to content

[SOLVED] Adding manufacturer description to product page


Recommended Posts

Hi, I want to add Manufacture Name and description into the product page (product.tpl)

I solved the name adding by adding this line:

{$product->manufacturer_name|escape:'htmlall':'UTF-8'}

But i also want the manufacture description to be displayed, I tryed this code but failed:

{$manufacturer->description|escape:'htmlall':'UTF-8'}

Please Help me!?

Link to comment
Share on other sites

  • 2 months later...

The code isn't working because the manufacturer object isn't being passed into product.tpl. To fix this, you need to add the following before the $smarty->display at the bottom of product.php:

$manufacturer = new Manufacturer($product->id_manufacturer, intval($cookie->id_lang));
$smarty->assign('manufacturer', $manufacturer);



Then you can use the following code anywhere in product.tpl in your theme's directory:

{$manufacturer->description}

Link to comment
Share on other sites

  • 2 months later...
  • 7 months later...
  • 4 months 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...