Adam Zerner Adam Zerner - 1 month ago 9x
AngularJS Question

Failed to execute 'postMessage' on 'DOMWindow': !== http://localhost:9000

This is the error message that I get:

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

I've seen other similar problems where the target origin is
and the recipient origin is
, but none like mine where the target is
and the origin is

  1. I don't get the problem. What is the problem?

  2. How can I fix it?


I believe this is an issue with the target origin being https. I suspect it is because your iFrame url is using http instead of https. Try changing the url of the file you are trying to embed to be https.

For instance:

var id = getId(url);
  return '//' + id + '?showinfo=0&enablejsapi=1&origin=http://localhost:9000';

to be:

var id = getId(url);
  return '' + id + '?showinfo=0&enablejsapi=1&origin=http://localhost:9000';