Dynamically setting Adobe Report suite with custom JavaScript

Bronze Contributor
Bronze Contributor

Could anyone advice on setting a report suite (i.e. dev or prd) programattically on the Adobe Analytics report suite or s_account?

I've tried setting it via the JS extension but it does not work.

 

utag_data.s_account = "test";

var prodDomainsArray = [
	'www.test.com',
	'test.com',
];

// SET PROD REPORT SUITE UNLESS OVERWRITTEN BY LAUNCH
if(prodDomainsArray.indexOf(window.location.hostname) > -1) {

	utag_data.s_account = 'prd';
}

 

 

2 REPLIES 2

Dynamically setting Adobe Report suite with custom JavaScript

Gold Contributor
Gold Contributor
Hi leodb,
I tried with your code in JS extension and it is working fine for me. What is the scope you are using for your extension. Have you tried scoping to the preloader ?

Thanks,
VJ

Dynamically setting Adobe Report suite with custom JavaScript

Tealium Expert
Tealium Expert

do you mean when the website url is DEV environemnt and or PROD environment.

IF you have the Tealium scripts setup properly across your dev environment and prod environment you can use a lookup data.

Lookup match the ut.env and then match it with the correct reportsuite.

Or if you have different website you can still use the lookup table so if domain equals "test.com" go to this report suite and so on.

https://community.tealiumiq.com/t5/iQ-Tag-Management/Lookup-Table-Extension/ta-p/13708


 

Damian Savvides
Public