Prestashop

Prestashop: Add custom column on Product Page and Display it on product.tpl

Steps:

  1. Create the table manually on the database.
  2. Declare the variable on /classes/product.php
  3. add the variable onĀ /controllers/front/ProductController.php in the following matter.

$product_tariff = $this->product->em_mg_tariff_code;
$this->context->smarty->assign('tariff_code', $product_tariff);

4. Add the field on your tpl on the following matter.

{$tariff_code}

 

 

Attachments:

Leave a Reply

Your email address will not be published. Required fields are marked *