Sunday, October 13, 2013

Opencart Description on Home Featured Products

Hey Friends

There are Some Steps for Display Description On home Page in Featured product section.

Step 1. Open catalog/controler/module/featured.php

And find in code :

'name'     => $product_info['name'],

 And add after Code:

'DESCRIPTION'    => $PRODUCT_INFO['DESCRIPTION'],

Step 2. now open catalog/view/theme/your-theme/template/module/featured.tpl
looking your location like :

<span class="price-old"><?php echo $product['price']; ?></span> <span class="price-new"><?php echo $product['special']; ?></span>
          <?php } ?>
        </div>

Add after this code :

<div style="min-height:140px;"><?php echo "<p>".mb_substr(strip_tags(html_entity_decode($product['description'])), 0, 150)."...</p>"; ?></div>

Thanks
Comments are most welcome :)