Ecom:Product.PrimaryImage

Version: 9.7.0 string  

Summary

Returns Primary image. 

Settings

The value is related to rendering of improved image pattern defined in shop, depends on 'Settings-Ecommerce-Advanced configuration-Images-Improved image patterns' option. Find extra details within the manual.

The value is rendered  per the availabilities:  

Default details OR Variant image pattern OR Master(Main) image pattern OR Missing image.

Examples

Outputting the template tag

@GetString("Ecom:Product.PrimaryImage")

Check if tag has a value

@if(!string.IsNullOrWhiteSpace(GetString("Ecom:Product.PrimaryImage"))) { @* Tag has value, so let's do something useful here. *@ }

Assign tag to a value for later use

@{ string storedTag = GetString("Ecom:Product.PrimaryImage"); }

Outputting the template tag

<!--@Ecom:Product.PrimaryImage-->

Check if string has a value

<!--@If Defined(@Ecom:Product.PrimaryImage)--> Let's output this tag here: <strong><!--@Ecom:Product.PrimaryImage--></strong> <!--@EndIf(@Ecom:Product.PrimaryImage)-->