Expand my Community achievements bar.

Applications for the 2024 Adobe Target Community Mentorship Program are open! Click to the right to learn more about participating as either an Aspirant, to professionally level up with a new Certification, or as a Mentor, to share your Adobe Target expertise and inspire through your leadership! Submit your application today.

Exclude from Activity after page loads

Avatar

Level 2

Is there a way to exclude a visitor from an activity after a page loads?  I have this scenario:

- On initial load I have body class ="classA"

- After about a second, the page gets updated with body class "ClassB" added. 

Is there a way for me to exclude this visitor from the activity once "ClassB" is added?

1 Reply

Avatar

Level 4

Target can't interact with the DOM to determine what HTML selector is present. You'd have to pass a parameter through the mbox to be able to Target. You could use a simple javascript function to check the DOM if the class exists and if it does pass a parameter into the mbox. Then you could build and audience with the class value.

Another option would be to insert the javascript in your offer that would look at the DOM, once loaded, and then call another mbox in the offer.

If you have more details of what you are attempting to do. Their might be some other solutions.