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

Cue the extraordinary. Show-stopping experiences that raise the digital bar. Apply now for the 2023 Adobe Experience Maker Awards.
SOLVED

Implement click event on iFrame

Avatar

Level 4

Hello there, I have an iFrame on a page and I'd like to fire a click event when a user clicks on the iframe. I don't really care about putting DTM code on the iframe, I just want to fire a click event when someone simply clicks on the container div itself. I've built a rule and applied every bubbling condition and element classname possible and the most I got was a rule-fire on the very edge of the container. Does anyone know how or why this is?

1 Accepted Solution

Avatar

Correct answer by
Level 2

Hi LeoS_Taco - I don't think we can track clicks on IFRAME embedded and referring to third party domains, however if it was hosted on same domain and you'don't want to add DTM library - you can use window.postMessage API for the same to set direct call rules.

View solution in original post

3 Replies

Avatar

Level 4

No it's a Facebook widget, so it just has a Facebook posts on it.

Avatar

Correct answer by
Level 2

Hi LeoS_Taco - I don't think we can track clicks on IFRAME embedded and referring to third party domains, however if it was hosted on same domain and you'don't want to add DTM library - you can use window.postMessage API for the same to set direct call rules.

The ultimate experience is back.

Join us in Vegas to build skills, learn from the world's top brands, and be inspired.

Register Now