Expand my Community achievements bar.

Join us for an upcoming in-person Adobe Target Skill Builders event ~~> We're hosting these live learning opportunities to equip you with the knowledge and skills to leverage Target successfully. Learn more to see if we'll be coming to a city near you!

Updating ACDL attribute for AEM component in Adobe Target Experience

Avatar

Level 3

I am trying to update a button component in the adobeDatalayer by editing the attribute data-cmp-data-layer.

For Example:

Control variant has below HTML

data-cmp-data-layer = {"button-ac7b87e127":{"showLeftIcon":"false","buttonType":"btn-primary","componentid":"button-ac7b87e127","xdm:linkURL":"/our-services/","arrow":"false","@type":"el/components/button/v1/button","interactionEventName":"hero_button_click","dc:title":"Read more","linkTarget":"_self","name":"button","interactionTitle":"Slide ","disabled":"false"}}

Variant A is updated to:

data-cmp-data-layer = {"button-ac7b87e127":{"showLeftIcon":"false","buttonType":"btn-primary","componentid":"button-ac7b87e127","xdm:linkURL":"/our-services/media/

","arrow":"false","@type":"el/components/button/v1/button","interactionEventName":"hero_button_click","dc:title":"Get in Touch Today","linkTarget":"_self","name":"button","interactionTitle":"Slide 2 ","disabled":"false"}}

As seen above, updates are made to dc:title, xdm:linkURL & interactionTitle. Rest of the properties remain the same.

Though the HTML of the button is updated when I checked using QA url. However noticed that updating the html attribute does not update properties in adobDatalayer

`

Also the rule which triggers on click of the button component does not work when I make the update for the variant.

How can I update the datalayer for the component to change properties like dc:title, xdm:linkURL and others? I am looking to track clicks to the button using the existing rule in launch.

If this cannot be done, what would be the next best way to track the button click?

Any reason why the rule doesn't work when tested using the QA url whereas it works on the site?

0 Replies