iFrame redirect and Adblock

2 replies
Hi,

I want to redirect a website from my domain to another, but Adblock is always blocking my redirect script and doesn´t load the iframe.

I have to redirect a website which also contain a redirect to another website.

Here is an example:

1) iFrame should redirect to domain A(still inside iframe) 2) Domain A should redirect domain B and leave the iFrame 3) Browse Domain B

MyDomain/Script -> redirect to Domain A-> Domain A redirects to Domain B

Tried it with jQuery and PHP-Proxy (redirect loop) but it is not working.. Maybe there is another way e.g JS,PY :-)

Is ther a way to do a server side redirect with ngnix?

Thanks for your help

Best regards
#adblock #iframe #redirect
  • Hi,

    Did you try this method:

    1. Create <iframe> 100% full screen

    Code:
    <iframe src="PUT_URL_HERE" wmode="transparent" width="100%" height="100%" FRAMEBORDER="0" style="position:absolute;top:0px;left:0px;right:0px;bottom:0px; height:100%;" SCROLLING="no" noresize></iframe>
    2. Method with data-URI

    a) First go to page "base64 encode". For example: https://www.base64encode.org/

    b) Now we need to change the code:

    Code:
    <script>window.location.href = "http://www.example.com"</script>
    ...to Base64 (base64 encode).

    Place the code in the form field and click ENCODE.

    c) Then copy the encoded code and place it in this template:

    Code:
    data:text/html;base64,PUT_HERE
    Result:

    Code:
    data:text/html;base64,PHNjcmlwdD53aW5kb3cubG9jYXRpb24uaHJlZiA9ICJodHRwOi8vd3d3LmV4YW1wbGUuY29tIjwvc2NyaXB0Pg==
    e) Place the created code in the attribute SRC:

    Code:
    <iframe src="data:text/html;base64,PHNjcmlwdD53aW5kb3cubG9jYXRpb24uaHJlZiA9ICJodHRwOi8vd3d3LmV4YW1wbGUuY29tIjwvc2NyaXB0Pg==" wmode="transparent" width="100%" height="100%" FRAMEBORDER="0" style="position:absolute;top:0px;left:0px;right:0px;bottom:0px; height:100%;" SCROLLING="no" noresize> 
    </iframe>
    If you need any help, please write.

    Best Regards,
    Arthur
    {{ DiscussionBoard.errors[10015138].message }}
  • Profile picture of the author KenWeiLL
    Multiple redirect is automatically blocked by Google Chrome and IE, especially if you use window.location.href for multiple redirection.

    Not a problem on Firefox though as this is allowed on Firefox.
    {{ DiscussionBoard.errors[10030809].message }}

Trending Topics