問題タブ [ytplayer]
For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.
iframe - setting up video play tracking on websites
I am trying to track different videos on a few websites. The videos are all hosted on YouTube and I have them embeded in some Joomla websites. I am trying to set up event tracking for the videos so that I can see which videos are being played on what websites. After much reading and researching I found that I needed to set up events and the youtube api. I have tried quite a few versions of this mixing up diff things but I still cant get events to trigger. (I think)
I have pieced together the following 'code' and placed it on the website. I have the video being embeded on the page and it plays, but when I go to ganalytics the event is not being triggered. What am I missing? I probably have more than I need as I am piecing it together. What I want to know is which video is played on the websites.
enter code here
javascript - ループ内の YouTube プレーヤーの複数のインスタンス
私は次のコードを持っていますが、これは機能しますが、理解できない部分は onReady イベントでインデックスを取得する方法です。結果は、私が期待する 0,1 ではなく 2,2 です - なぜですか?