Iframes and HTML Block

Permalink
I have searched the forum but have not yet found a working answer.

Why would the following iframe cause a "File Not Found" error when dropped into an HTML Block?

<iframe width="560" height="315" src="https://www.youtube.com/live_chat?v=Aqg8Tafmqds&embed_domain=www.truthfactor.com" frameborder="0" allow="autoplay; encrypted-media" allowfullscreen></iframe>


Is there some issue with using iframes in the HTML block?

The above iframe is for a Youtube chat window. I had the same problem embedding the Youtube Live viewing window using iframe so I switch that to the Youtube Video block which seemed to work.

Thoughts?

Thanks!

 
PineCreativeLabs replied on at Permalink Reply
PineCreativeLabs
I just tried to embed that iframe, and in the error console, I got:
Refused to display 'https://www.youtube.com/live_chat?v=Aqg8Tafmqds&embed_domain=www.truthfactor.com' in a frame because it set 'X-Frame-Options' to 'sameorigin'.


This means that it is a permission issue, so displaying it in an iframe isn't an option. In other words, YouTube has blocked this from being embedded in third party sites. This is due to security issues, as the embeded content could be exploited.

Perhaps displaying it via some other method, such as ajax, could be an option.
stewblack23 replied on at Permalink Reply
stewblack23
Hey Johnduvall

Looks like you are embedding a live stream or chat from youtube. I'm pretty sure youtube will not let you do that because of security concerns. Try a normal youtube video with the same code and see if that works.