AD0-E409 · Question #73
The client ran A/B Test activities on their website for a year without the Tag Management System. The client is now using a data layer and asks the Adobe Target Architect to use values from the data…
The correct answer is B. In the <HEAD> section before referencing at.js. Option B is correct because at.js executes immediately upon loading and needs the data layer values to already exist in the JavaScript environment to use them for personalization decisions. By placing the data layer in the <HEAD> before at.js, those variables are guaranteed to…
Question
The client ran A/B Test activities on their website for a year without the Tag Management System. The client is now using a data layer and asks the Adobe Target Architect to use values from the data layer for website personalization. Where should the Adobe Target Architect recommend placing the data layer?
Options
- AIn the <HEAD> section after referencing at.js
- BIn the <HEAD> section before referencing at.js
- CAt the bottom of the <BODY> section after referencing at.js
- DAt the bottom of the <BODY> section before referencing at.js
How the community answered
(18 responses)- A6% (1)
- B72% (13)
- C17% (3)
- D6% (1)
Explanation
Option B is correct because at.js executes immediately upon loading and needs the data layer values to already exist in the JavaScript environment to use them for personalization decisions. By placing the data layer in the <HEAD> before at.js, those variables are guaranteed to be available the moment at.js initializes and fires its personalization logic.
Option A fails because placing the data layer after at.js means at.js runs first without any data layer context - it's already made its decisions before the data arrives.
Option C and D both fail because placing anything in the <BODY> bottom means at.js (correctly in the <HEAD>) has already executed long before those scripts load, causing content flicker and missed personalization - the core problem at.js in the HEAD is designed to prevent.
Memory tip: Think "set the table before the guest arrives." The data layer is the table setting; at.js is the guest. The guest (at.js) needs the table ready (data layer) the moment it walks in - so data layer always comes first, in the <HEAD>.
Topics
Community Discussion
No community discussion yet for this question.