HTML script block requirements
Requirements for coding your web pages.
- Reference eluminate.js, the data collection library, in the <head> section of the page, within a <script>.
- Reference the cmSetClientID() call in the <head> section of the page, within a <script> block as shown in the example.
- Define the digitaldata object in the <head> section of the page, within a <script>. The value that is entered for the JavaScript object name needs to exist on the page exactly as it is entered in the Object Name field in the tag configuration.
- If you are using the default JavaScript Object page identifier for your deployment, define a pageInstanceID value in every web page to be evaluated by DDX page group rules.
This example shows an IBM® Digital Analytics Page View Tag with the standard values used by Digital Analytics, and all parameters populated with sample data.
<HEAD><TITLE></TITLE>
<script type="text/javascript" src="//libs.coremetrics.com/eluminate.js"></script>
<script type="text/javascript">
cmSetClientID("69999999 or 59990000|siteid",false,"testdata.coremetrics.com",
"yoursite.com"); //send data to test reporting.
</script>
<script type="text/javascript"> digitalData = { page:{pageInfo:
{pageID:'UNIQUE PAGE ID VALUE',onsiteSearchTerm:",onsiteSearchResults:"},
category:{primaryCategory:"},attributes:{exploreAttributes:",ExtraFields:"}},
pageInstanceID:'standard-page' };
</script>
</HEAD>