pdf - GTM dataLayer.push() not working -


i tracking pdf download using custom metric. have written following code

<script> datalayer.push({'dlpdfdownload': 1}); </script> 

dlpdfdownload datalayer variable name have created in gtm v2.

script executing problem value pdf download doesn't increment if download particular pdf many time. value in custom metric remains 1 doesn't increment download.

what changes need make in script value increment every time download pdf

your question incomplete. i'm going assume context using google analytics gtm , have created custom metric in property settings.

the custom metric incremented if send along google analytics hit. need numeric index metric in property settings. need set analytics tag triggeres when pdf downloaded, e.g. link click trigger. in tag expand "custom metrics" section, enter numeric index of dimension in index field , datalayer variable in value field.

if doing, or if have misunderstood problem, need amend question more information.


Comments