+ 1
I keep getting this error. Please tell me what I am doing wrong.
I am building a webpage in Code Playground and I added a youtube video to the page. When I hit run, the video shows and plays on the page but I keep getting this error: Unsafe JavaScript attempt to access frame with URL about:blank from frame with URL file https//youtube.com/embed/hoy19ZFRbeE. Domains, protocols and ports must match. I used this code to put the video on the page: <iframe src=" https://www.youtube.com/embed/hoY19ZFRbeE" width="300" height="315"></iframe> What am I doing wrong?
5 Answers
+ 6
I cannot reproduce your error ( tested with @Calvin Lee link ), but maybe you can try to use the Iframe Player API from Youtube to handle video player dynamically:
https://developers.google.com/youtube/iframe_api_reference#Loading_a_Video_Player
+ 4
Your code can run without issue. Please double check.
https://code.sololearn.com/WRxL4g80WUHG/?ref=app
+ 1
Try https instead of http in your link.
+ 1
@Jeth, I tried that. Still the same error.