0

I am Stuck in very weird situation where I want to remove the tax that is displayed in the cart when tax setting is set to display catalog prices including tax. I tried to remove this by setting taxclassID to 0 but didnot get any result please help me.

1 Answer 1

1

I got the following code that is used to remove any type of tax irrespective of inclusive or exclusive

$inc=$address->getGrandTotal();
                            $tax=$address->getTaxAmount();
                            $exc_tax = $address->getGrandTotal() - $address->getTaxAmount();
                            $address->setSubtotalInclTax($exc_tax);
                            $product->setPrice($exc_tax);
                            $product->setTaxClassId(0);
                            $finalPrice=$exc_tax;

I hope this will help you all

Your Answer

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

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