Ecom:Product.Type
Version: - integerSummary
Returns an integer that represents the type of the product.
Settings
The value is based on the Type dropdown for a product.
(Ecommerce > Products > Shop > Product group > Product > Details > Settings panel)
Remarks
Types:
- Stock item
- Service
- Parts list
- Gift card
Examples
Outputting the template tag
@GetInteger("Ecom:Product.Type")
Check if tag has a value
@if(!int.IsNullOrWhiteSpace(GetInteger("Ecom:Product.Type"))) {
@* Tag has value, so let's do something useful here. *@
}
Assign tag to a value for later use
@{
int storedTag = GetInteger("Ecom:Product.Type");
}
Outputting the template tag
<!--@Ecom:Product.Type-->
Check if integer has a value
<!--@If Defined(@Ecom:Product.Type)-->
Let's output this tag here: <strong><!--@Ecom:Product.Type--></strong>
<!--@EndIf(@Ecom:Product.Type)-->