Ecom:VariantCombination.Product.Price
Version: - priceSummary
Returns the price of the product variant.
Settings
The value is based on the Price
input field under the General
tab for a product.
Remarks
Includes the option to add price extensions in order to format the price. See Price extensions
(Prefix : Ecom.VariantCombination.Product.Price)
Examples
Outputting the template tag
@GetPrice("Ecom:VariantCombination.Product.Price")
Check if tag has a value
@if(!double.IsNullOrWhiteSpace(GetPrice("Ecom:VariantCombination.Product.Price"))) {
@* Tag has value, so let's do something useful here. *@
}
Assign tag to a value for later use
@{
double storedTag = GetPrice("Ecom:VariantCombination.Product.Price");
}
Outputting the template tag
<!--@Ecom:VariantCombination.Product.Price-->
Check if price has a value
<!--@If Defined(@Ecom:VariantCombination.Product.Price)-->
Let's output this tag here: <strong><!--@Ecom:VariantCombination.Product.Price--></strong>
<!--@EndIf(@Ecom:VariantCombination.Product.Price)-->