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

CRITICAL ISSUE - Adobe Target is loaded twice when added the Custom code container


Level 2


Last week we updated the latest AEM Service Pack to PRD. After this release we got some critical issues with Adobe Target:

- Adobe Target is loaded twice when added a Custom code container in the body (With some simple console log). Causing some components not to load

When you remove the custom code container from the activity, target is only loaded once (Normal)

- When you add a custom code container in the head tag, target is doing fine and is only loaded once (Normal)


Adobe Target is loaded via Adobe Launch or "Data Collection"

Any ideas to fix the issue for body tag?


Please let me know if you need more information.


Kind regards,


1 Reply


Level 4

Hi @Ewoud_p

How exactly do you put your custom code on the page? Via a target activity using the VEC and an HTML element? Or via something else?


I can only think of two experiences at the moment - but they don't have to have anything to do with your problem.


If you use remote offers that bring code to the page via a JCR path - depending on the setup this may require that you first have to check what exactly arrives in the remote offer in the request. Once had the case that depending on the RemoteOffer of AEM corresponding scripts were automatically added to the page. But this can be easily fixed with a small script and only allow scripts that are not yet included on the page.


With a customer was once the current live stand differently than expected. There was still an at.js implemented for testing purposes. In addition, the normal rule implemented the appropriate target. This was noticed when we checked the request in the network tab and found that a completely different at.js was loaded.