Example - create a trigger
In this example, you create a trigger and add a variable mapping to it. Triggers let you automatically fill in template variables using metadata from a Sitecore Content Hub entity, for example Product, as well as frames, using assets related to that entity. Adding a variable mapping automatically fills in a template variable with a Product property, such as its name, and adding a frame mapping fills in a frame with an asset related to that product.
To create a trigger:
-
On the menu bar, click Publisher > Templates.
-
On the Templates page, click the template you want to modify.
-
On the template details page, on the Triggers tab, click
Trigger.
-
In the Trigger dialog, in the Source relation drop-down list, click Products and then click Add mapping.
-
In the Store property drop-down list, click Short description.
-
In the in template variable drop-down list, click your desired variable.
-
Click Save.
For example, when you change the Selected product field to Lime, the Slogan automatically changes to The best lime juice in the world:
Orange selected product |
Lime selected product |
---|---|
![]() |
![]() |
![]() |
![]() |