Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

SOLVED

Issue with data element

scottt6073095
Level 6
Level 6

I created a data element with the below custom code and have it firing on a pageload rule (bottom of page but also same results with top of page) in DTM. Everything looks good except I get a few instances of my strings I am passing but randomly truncated. (see image below). Is there a way to ensure the whole string gets passed appropriately?

var adBlockDetection = (function() {
var test = document.createElement('div');
  test.innerHTML = ' '; //non-breaking space in div element
  test.className = 'adsbox'; //"adsbox" is on the adblocker definition list and will get blocked
  document.body.appendChild(test); // add the definition to the fake ad (div)
   if (test.offsetHeight === 0) {
     //console.log("AdBlocker Status: Active");
     return "AdBlocker Status: Active";
    } else {
     //console.log("AdBlocker Status: None");
     return "AdBlocker Status: None";
    }
})();

return adBlockDetection;

1 Accepted Solution
jantzen_belliston-Adobe
Correct answer by
Level 10
Level 10

Have you been able to replicate this behavior yourself? It looks like it's happening less than 0.1% of the time so I imagine replicating it is going to be difficult. Have you done further analysis of the data to know where these hits are coming from? I'd like to know if they are isolated to a specific browser, region, mobile device, etc.

View solution in original post

3 Replies
ParitMittal
Level 10
Level 10

HI Scott,

Ideally this shouldn't have been the case because eVar has a length of 255bytes and the "AdBlocker Status: Active" is less than it. Can you please share your DTM account details as well as URL of the website in a private message so that we can debug the issue at our end.

Thanks & Regards

Parit Mittal

jantzen_belliston-Adobe
Correct answer by
Level 10
Level 10

Have you been able to replicate this behavior yourself? It looks like it's happening less than 0.1% of the time so I imagine replicating it is going to be difficult. Have you done further analysis of the data to know where these hits are coming from? I'd like to know if they are isolated to a specific browser, region, mobile device, etc.

View solution in original post

ParitMittal
Level 10
Level 10

Hi Scott,

Have you done further analysis of the data to know where these hits are coming from ?

Thanks &  Regards

Parit Mittal