Page 1 of 1

price on add to cart

Posted: Tue Feb 19, 2008 4:38 pm
by jenny
norman
i have the code to put the price on the add to cart button but that gives the prevat price. so how can i get the actual price displayed.
your help would be appreciated.
Jenny

<!-- CartButton HTML begin -->
<!-- This template is used for the add to cart button. -->
<INPUT TYPE=SUBMIT value="<Actinic:Variable Name="CartButtonText"/> £<actinic:block php="true"> echo number_format('<actinic:variable encoding="perl" name="ProductPriceRaw"
selectable="false" />',2);
</actinic:block>" class='forminput' NAME="<actinic:variable name="ProductReference"/>">

<!-- This template is used for the add to cart button. -->
<!-- CartButton HTML end -->

Re: price on add to cart

Posted: Wed Feb 20, 2008 11:52 am
by norman
Amend

Code: Select all

echo number_format('<actinic:variable encoding="perl" name="ProductPriceRaw" selectable="false" />',2);
to be

Code: Select all

echo number_format(1.175 * '<actinic:variable encoding="perl" name="ProductPriceRaw" selectable="false" />',2);
This assumes that all your products are VATable.