WordPress.org

Support

Support » Plugins and Hacks » [Resolved] [Plugin: Advanced iframe] Action on External Site – How to keep it in iFrame?

[Resolved] [Plugin: Advanced iframe] Action on External Site – How to keep it in iFrame?

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author mdempfle

    @mdempfle

    Seems the remote site does use a frame breaker.

    There are a couple of anti frame busting scripts.
    See
    http://coderrr.wordpress.com/2009/06/18/anti-anti-frame-busting/

    I have not played around with this. If you have success please tell me an I try to integrate it into the plugin.

    Thanks for the link.
    However, I’m not a programmer.
    Where exactly do I include this code?

    Plugin Author mdempfle

    @mdempfle

    I just checked a couple of implementations and if you are not a programmer it is not that easy because none of the examples are ready to use.

    I will put this on my todo list and implement one for 2.1 because I think this is interesting too ;).

    I can send you a first version if you like.

    – Michael

    I’d be happy to be the Beta-Tester. 😉

    Plugin Author mdempfle

    @mdempfle

    Hi,

    I have done some more investigation and some tests.

    I made s simple page with an iframe breaker and was possible too keep it in the frame.

    But I also had the issue that when the blocker script was enabled other links on the parent page where not working anymore.

    If you want to try:

    put:

    var prevent_bust = 0;
    // Event handler to catch execution of the busting script.
    window.onbeforeunload = function() { prevent_bust++ };

    // Continuously monitor whether busting script has fired.
    setInterval(function() {
    if (prevent_bust > 0) { // Yes: it has fired.
    prevent_bust = 0; // Avoid further action.
    // Get a ‘No Content’ status which keeps us on the same page.
    window.top.location = ‘http://localhost/204.php’;
    }
    }, 1);

    into the ai.js
    and create a file 204.php with the content
    <?php
    header(“HTTP/1.0 204 No Content”);
    ?>

    on your server. Then change the http://localhost/204.php that it points to your 204.php.

    Make sure to clean all browser caches when you test.

    I’m currently not really happy with this solution.

    You can try and tell me if you are ;).

    You see the examples here:
    http://en.wikipedia.org/wiki/Framekiller

    I also tested the alternative solution from there where a message is shown. But this also has the problem that the message is shown on EVERY link on the page.

    So please give me your thoughts.

    Michael

    Plugin Author mdempfle

    @mdempfle

    Feedback?

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘[Resolved] [Plugin: Advanced iframe] Action on External Site – How to keep it in iFrame?’ is closed to new replies.