nationalarchives / legacy-tna-google-tag-manager-scripts

All scripts to be added into google tag manager can be found here.
MIT License
4 stars 1 forks source link

Set up custom dimensions in GTM and GA #91

Closed hoake closed 4 years ago

hoake commented 4 years ago

Dependencies

GA set up

Add the following custom dimensions to TNA property customDimension4: Other Archive datasource (hit based) customDimension5: Archive place or repository (hit based) customDimension6: Other Archive document reference (hit based) customDimension7: Repository location (hit based) customDimension8: Discovery reader type (session/user based)

GTM set up

Create the following variables

Variable type: DataLayer

Name: Data Layer Variable Name:
DLV - customDimension4 - OA datasource customDimension4
DLV -customDimension5 - Repository customDimension5
DLV -customDimension6 - OA doc ref customDimension6
DLV -customDimension7 - Repository loc customDimension7
DLV -customDimension8 - Reader type customDimension8

Edit Variable type: Discovery global settings to add the above customDimensions

Acceptance/test criteria using GTM preview and GA debug

Page where the meta tags for customDimensions 4-7 do not exist no value should be sent. CustomDimension8 should be available on every page in Discovery.

CHECK PAGES THAT DO NOT CONTAIN EXPECTED VALUES