• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Blocking a break out of Iframe

Enthusiast ,
Feb 06, 2012 Feb 06, 2012

Copy link to clipboard

Copied

I have a site that relies upon keeping a 3rd party site inside an Iframe. The problem is that the site is breaking out of the IFRAME using break out code.

I did some research and could not seem to find a reliable way to stop the 3rd party from breaking out, some of it may actually be caused by a popup that pops over the iframe which also causes a break out.

Anybody have any methods of stopping this?

Thanks

Mark

TOPICS
Advanced techniques

Views

1.0K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 06, 2012 Feb 06, 2012

Copy link to clipboard

Copied

I have a site that relies upon keeping a 3rd party site inside an Iframe.

This is a bad reliance to have. Why should your site be able to keep mine inside a frame?

The only way to absolutely, positively avoid this is to fetch the contents via HTTP, rewrite them as desired, then serve them yourself. You can definitely do that from within CF. You might also be able to do that from within your client-side code via AJAX calls, but you might not - that seems a bit dicey. In either case, you may well be violating the terms of use of whatever content you're serving.

Dave Watts, CTO, Fig Leaf Software

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Enthusiast ,
Feb 06, 2012 Feb 06, 2012

Copy link to clipboard

Copied

LATEST

Hi Dave,

It's actually part of a mobile platform where we run advertisers WAP sites inside our platform, and we have to retain certain control buttons at all times, hence the need for the IFRAME. I don't think re-wrting the content ourselves would be a good idea as it will potentially mess up our tracking.

I'm going to see if our mobile SDK can handle it.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation