Search code examples
popupadblock

AdBlock Plus or NoScript: How to block this ad?


I tried to block the annoying popup advertisement on movie-blog[dot]org but nothing helps. I tried several strings with AdBlock Plus. I analyzed the code with Firebug to get the frame code. No success yet.

For example, i tried this and several other strings:

##IFRAME[id="shpujixmntsgsyquogzm"][src="https://www.stargames.com/nrgs/de/landing?refererId=79465*"]

##script[src^="http://displayad.layer-ad.org/delivery/ad.php?*"]

Anyone able to block the popup with AdBlock Plus or NoScript?


Solution

  • This one should work: ||www.movie-blog.org/layer/layernew5.js^$domain=movie-blog.org,script

    Here are some notes why:

    • Filters that contain ## are merely for hiding elements that are already on the page (i.e. <iframe>, etc.) so the ad won't be prevented from downloading by using those.
    • Element hiding filters work with regular CSS selectors and those don't support using * as a placeholder character such as in ad.php?*.
    • To prevent a resource from downloading you need to write a blocking filter to match its URL such as the one I suggested above.
    • The "ad.php" resource is already being blocked so that one's not causing the ad to appear. Instead, the "layernew5.js" script appears to be responsible for it.

    And some more info on the filter I suggested:

    • || is a placeholder for http:// and https://
    • ^ is a placeholder for the end of the string or other separator characters
    • $ separates the match pattern from the filter options
    • domain=... limits the filter to only be active on that domain
    • script limits the filter to JavaScript resources

    Source: https://adblockplus.org/filters