Data elements are designed to return a value for use across page load, event triggered and direct call rules. The returned value can be based on a url query parameter (campaign tracking), pre-existing javascript objects (member id), CSS element (value of div with id=‘xyz’), cookie, or custom script that performs some logic or manipulates the raw value before passing it on to your rules.
Below are 3 examples of how you could pick up the author of a blog article based on: a predefined javascript variable; a div with the id=’authorName’; or a url parameter called ?authorName.
DTM ways of creating data elements
So how do you use data elements?
In 2 ways;
1. capture, manipulate and move data into SiteCatalyst and other singapore email list 1.6 million contact leads platforms linked to DTM
2. as a condition for a page load rule to run, based on the value of the specified data element/s.
Page load rules, as the name suggests, will run on load of every page when no conditions have been set. The value of a data element can be used as a condition for running a page load rule, meaning that on the load of the page DTM will go and source the current value of specified data elements (data elements are set prior to rules), and based on the conditions applied to the value of that data element, either run or ignore the rule on page load.
A common example is a blog post where you want to trigger specific variables and events as a separate page load rule, but don’t want the rule to run across all pages. Here you would make the page load rule conditional where the data element ‘Page Type’ is equal to ‘Blog Post’: