brandly / angular-youtube-embed

:tv: Embed a YouTube player with a simple directive

Home Page:http://brandly.github.io/angular-youtube-embed/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Failed to execute 'postMessage' on 'DOMWindow': The target origin provided does not match the recipient window's origin

4z5lz opened this issue · comments

commented

Hi,
First of all, very nice directive! Good job!

Sometimes, I get error "Failed to execute 'postMessage' on 'DOMWindow': The target origin provided ('https://www.youtube.com') does not match the recipient window's origin ..."

How can I solve it?

Thanks

hey! i've seen this error before and never worried about it, since everything seemed to function fine

however, it looks here like it's an issue with mixing http and https requests

are you using https://www.youtube.com/iframe_api over https or http? it looks like http will cause that error to be thrown

let me know!

commented

I have a page on https and using https://www.youtube.com/iframe_api

Any solution on this? I'm facing the same issue, and I think as a result of that, the embeded youtube player doesn't play