0

In Magento 2.4.3 configuration, I have set:

Display Product Prices In Catalog: Including and Excluding Tax

If the product has a special price, then the only special price is displayed including/excluding tax, while the old price is displayed only as including tax.

enter image description here

How can I fix this?

3 Answers 3

0

Try I have a manual solution for the excl Regular Price. You have to override the file in your theme

app\design\frontend\<VENDOR_NAME>\<THEME_NAME>\templates\product\price\final_price.phtml

and add content in to the file after the old-price <span>:

<span class="old-price">
    <span class="price-label">excl Regular Price</span>
    <span class="price-wrapper price-excluding-tax">
        <span class="price">
            <?php /* @escapeNotVerified */ echo $this->helper('Magento\Framework\Pricing\Helper\Data')->currency(number_format($priceModel->getAmount()->getBaseAmount(),2),true,false)?>
        </span>
    </span>
</span>

enter image description here

0

Just change 'price_type' to baseOldPrice.

<span class="old-price sly-old-price no-display">
        <?= /* @noEscape */ $block->renderAmount($priceModel->getAmount(), [
            'price_id'          => $block->getPriceId('old-price-' . $idSuffix),
            'price_type'        => 'baseOldPrice',
            'include_container' => true,
            'skip_adjustments'  => true
        ]); ?>
</span>
-1

Please can you follow this path in Backend :-

Admin >> Stores >> Configuration >> Sales >> Tax >> Price Display setting.

Hope this helpful thanks.

2
  • I have already mentioned in description, that I have set this to "Including and Excluding Tax"
    – zekia
    Dec 17, 2021 at 10:25
  • This solution has been working fine. If you config and it doesn't work, please check your site again. It may be installed incorrectly or missing magento.stackexchange.com/a/33056/101754 Dec 21, 2021 at 3:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.