Cart Tax
{exp:cartthrob:cart_tax} outputs the current tax total for the cart.
This is commonly shown in cart and checkout summaries.
See also:
Parameters
This tag has no tag-specific parameters.
Default output is formatted through ExpressionEngine’s number formatter.
Use :numeric when you need an unformatted value for calculations.
Modifiers
To get a raw numeric value for the cart tax total:
{exp:cartthrob:cart_tax:numeric}
Output and Behavior
- Base value comes from
cart->tax(). - Tax calculation includes:
- item tax
- shipping tax
- minus discount tax
- The result is never returned below
0. - If there are no taxable items, shipping tax can still be returned when applicable.
:numericreturns the raw numeric value; default output is formatted text.
Example
Basic cart tax
{exp:cartthrob:cart_tax}
Raw numeric tax value
{exp:cartthrob:cart_tax:numeric}