Expand my Community achievements bar.

SOLVED

Tags - YouTube iFrame Tracking Problem

Avatar

Level 9

Hi guys,

 

I am facing an issue where I cannot seem to receive any YT iFrame media events (iframe src contains the &enablejsapi=1 param, see sample src below).

 

Setup

  • youtube video is loaded upon click on poster i.e., iframe with src *= youtube is not available before click
  • using the "Youtube Playback" extension, https://exchange.adobe.com/apps/ec/104160
  • tried a poster click rule that was not working reliably, saying the iframe was not found by then (did not want to add a delay)
  • instead, opted for a "enters viewport" solution (only as a POC, will be refactored later), just to see if anything is fired at all - which is not

Sample iFrame source

src="https://www.youtube.com/embed/asdasdadsadsadsadsads?autoplay=0&controls=0&disablekb=1&playsinline=1&...enablejsapi=1&origin=https%3A%2F%2Fwww.client.com&widgetid=1"

 

bjoern__koth_0-1721215976411.png

 

bjoern__koth_2-1721216099700.png

 

It seems to detect the iframe with the player.

bjoern__koth_1-1721216040448.png

 

However, my dummy rule that should fire upon pretty much any YT event is never called

bjoern__koth_3-1721216122092.png

 

Any ideas?

 

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

1 Accepted Solution

Avatar

Correct answer by
Level 9

@yuhuisgwho created the extension brought me on the right track. The developers are using a custom player that integrates various sources like YouTube, Vimeo, etc and instead exposes standard HTML5-style media events I should be able to register to.

Unfortunately, this player comes with its own iframe_api.js which causes problems with the extension.

 

Solution will be using the custom events coming from the player and skipping all Launch extensions.

View solution in original post

2 Replies

Avatar

Correct answer by
Level 9

@yuhuisgwho created the extension brought me on the right track. The developers are using a custom player that integrates various sources like YouTube, Vimeo, etc and instead exposes standard HTML5-style media events I should be able to register to.

Unfortunately, this player comes with its own iframe_api.js which causes problems with the extension.

 

Solution will be using the custom events coming from the player and skipping all Launch extensions.