How to display price in product page with and without tax in Prestashop 1.7?

Viewed 5576
2 Answers

Since version 1.7.6, displayPrice method is deprecated. Use formatPrice instead. For example in templates/catalog/_partials/miniatures/_partials/product-prices.tpl:

{block name='product_without_taxes'}
    {if $priceDisplay != 1}
        <p class="product-without-taxes">{l s='%price% tax excl.' d='Shop.Theme.Catalog' sprintf=['%price%' => Context::getContext()->currentLocale->formatPrice($product.price_tax_exc, $currency.iso_code)]}</p>
    {/if}
{/block}
Related