Is it possible to make the Tax/VAT number field required in checkout page, if order total was more than x? How?
Thanks
orderstaxvat
Is it possible to make the Tax/VAT number field required in checkout page, if order total was more than x? How?
Thanks
Best Answer
You can achieve this with the following:
Copy
app/design/frontend/base/default/template/checkout/onepage/billing.phtml
and/orapp/design/frontend/base/default/template/checkout/onepage/shipping.phtml
to your template folderadd the check on the total value (subtotal, grand total,..) in the class attribute and change YOUR_TOTAL_AMOUNT to the total amount which you need as limit:
<?php echo $this->getQuote()->getGrandTotal() >= YOUR_TOTAL_AMOUNT ? "required" : ""; ?>
The code of your input-form should look like this now:
I didn't test it, but I think it should work #yolo.