Quote:
You need it to be of that form which was stated above.
You have to assign the variables for the math equation for smarty to use them.
|
Unfortunately, using the snippet below (which I agree, looks like it should work fine) doesn't.
Quote:
{math equation="(sub_total+discount+shipping_cost)*0.02"
sub_total=$cart.sub_total
discount=$cart.discount
shipping_cost=$cart.shipping_cost
assign="surcharge"
format="%.2f"}
|
And it gives me this error message
Quote:
Warning: Smarty error: math: parameter sub not passed as argument
|
A real head-scratcher...
