iframe cross origin policy in IE

569
November 22, 2016, at 1:46 PM

Which versions of IE throw an exception if we try to access the cross origin data ?

IE doesn't throw exception if I call $('iframe[name="iframe"]').contents().find('body') in my javascript code

However, chrome and firefox do

DOMException: Failed to read the 'contentDocument' property from 'HTMLIFrameElement': Blocked a frame with origin "http://localhost:8080" from accessing a cross-origin frame.(…)

Answer 1

That has been included since IE7.

The reason you're not having any issues with it, is because you've set your privacy settings in IE to allow local and cross domain communication.

There are a few ways to bypass this depending on what you're trying to do.

Rent Charter Buses Company
READ ALSO
How can I make Slick Slider height responsive?

How can I make Slick Slider height responsive?

I have a working Slick Slider (http://kenwheeler. github.

1045
how to link to a specific tab by jquery

how to link to a specific tab by jquery

I have 2 html pages. [nnn]Page 1 has 3 tabs with contents.

355
ColdFusion Query from SQL converted into JS ARRAY

ColdFusion Query from SQL converted into JS ARRAY

I have a sql database that I would like to query with coldfusion and set up into a js array. So that I can run my JS function to display a certain date.

325