Blocking an ad based on the size of the image.

Everything about using Adblock Plus on Mozilla Firefox, Thunderbird and SeaMonkey
Post Reply
Demented Gerbil
Posts: 1
Joined: Fri May 19, 2017 12:34 am

Blocking an ad based on the size of the image.

Post by Demented Gerbil »

So one of my favorite sites has started a campaign to advertise for something, and every single bit of the content is infested with the same exact picture over and over and over again. They tend to do this often, as well as use this space for regular obnoxious ads otherwise. The problem is right clicking the ad offers no block option. Digging into the page code reveals that the ad has an ID and a class that is entirely randomized when the page is loaded, and each occurrence of that ad has its own different random ID. The image name itself is an endless string of garbage text that is randomized, too.

The code that generates it is as follows:

Code: Select all

<style type="text/css">#hbJzLoRC { display: block !important;position: absolute !important;margin: 0 !important;border: 0 !important;padding: 0 !important;width: 970px !important;height: 250px !important;min-width: 0 !important;max-width: none !important;min-height: 0 !important;max-height: none !important;background: url(data:image/jpeg;base64,/9j/4QAYRXhpZgAASUkqAAgAAAAAAAAAAAAAAP/sABFEdWNreQABAAQAAABBAAD/4QOBaHR0cDovL25zLmFkb2JlLmNvb --- blah blah not posting the entire garbage text which would literally fill this entire page.
The only thing common between all the ads in the size. 970 x 250. The ad is always this size regardless of what is being advertised. But I can't seem to figure out how to make a filter for it. Is there a way to put something together to flush this obnoxious turd out of my screen space forever? Even if it just removes the image.

Thanks in advance for any suggestions.
User avatar
mapx
Posts: 21940
Joined: Thu Jan 06, 2011 2:01 pm

Re: Blocking an ad based on the size of the image.

Post by mapx »

try using abp-properties filters, see:
development-builds/new-css-property-filter-syntax

example page ?
Post Reply