IOs: locked frame with source "https://www.youtube.com" from access to frame with source

I know this question has been asked and answered a million times . But. Right now, I'm testing a site where Youtube iframe is included with iOS. It looks like this:

<iframe width="100%" height="200" src="//www.youtube.com/embed/my-video-id" class="yt-player-listed " frameborder="0" allowfullscreen></iframe> 

So, just the basic code provided by Youtube . It works great on most devices. But on iOS Safari:

 Blocked a frame with origin "https://www.youtube.com" from accessing a frame with origin ... from html5player.js:816 

I do not see protocol inconsistencies while I use // (I also tried using http: and https :): iframe just doesn't display .

I tried:

  • changed the protocol (http, https, //)
  • deleted all attributes in iframe (allowfullscreen, frameborder)

I don’t know what is going on there ...

+6
source share

Source: https://habr.com/ru/post/985578/


All Articles