Jump to content

Formatting in short description


Recommended Posts

  • 2 months later...
  • 5 months later...
The line of code you need to change is line 10 of product-list.tpl in your theme directory:

{$product.description_short|strip_tags:'UTF-8'|truncate:360:'...'}



Remove |strip_tags:'UTF-8' and the HTML tags won't be deleted.



works like charm my friend thank you very much for this usefull tip :)
Link to comment
Share on other sites

  • 10 months later...

In PrestaShop v1.3.1, you need to change line 9 of product-list.tpl in your theme's directory from:


<a href="{$product.link|escape:'htmlall':'UTF-8'}" title="{$product.description_short|strip_tags:'UTF-8'|truncate:360:'...'}">{$product.description_short|strip_tags:'UTF-8'|truncate:360:'...'}



to:


<a href="{$product.link|escape:'htmlall':'UTF-8'}" title="{$product.description_short|strip_tags:'UTF-8'|truncate:360:'...'}">{$product.description_short|truncate:360:'...'}

Link to comment
Share on other sites

Yep, just tested it on my test site and it worked fine. The formatting and line breaks were no longer removed after making the change. I'm not sure why it isn't working for you. I'm using the default PrestaShop theme.

Link to comment
Share on other sites

  • 2 years later...
×
×
  • Create New...