Simple Image filter by width/height (size)

Posting here is no longer possible, please use the forum of a filter list project, such as EasyList
Locked
asimo
Posts: 3
Joined: Fri Apr 24, 2015 5:05 pm

Simple Image filter by width/height (size)

Post by asimo »

Hi,

it seems that I'm to dumb to understand the filter syntax. Lets say we have this image:

Code: Select all

<img src="image.jpg" width="728" />
I'm able to block all images with a width of 728 by that filter:

Code: Select all

##img[width="728"]
Now I want this rule only to work on a specific domain, so I tried that:

Code: Select all

||example.com##img[width="728"]
But this rule does not do anything?!
User avatar
mapx
Posts: 21940
Joined: Thu Jan 06, 2011 2:01 pm

Re: Simple Image filter by width/height (size)

Post by mapx »

correct hiding filter

Code: Select all

example.com##img[width="728"]
en/filters
en/filter-cheatsheet
asimo
Posts: 3
Joined: Fri Apr 24, 2015 5:05 pm

Re: Simple Image filter by width/height (size)

Post by asimo »

But the manual says:
Sometimes one wants to block http://example.com/banner.gif as well as https://example.com/banner.gif and http://www.example.com/banner.gif. This can be achieved by putting two pipe symbols in front of the filter which makes sure the filter matches at the beginning of the domain name: ||example.com/banner.gif will block all these addresses
I thought by that "||" means something like a wildcard?!

Next question: How do I block an image by width, if this has no width set in html and style?!

Code: Select all

<img src="image.jpg" />
User avatar
mapx
Posts: 21940
Joined: Thu Jan 06, 2011 2:01 pm

Re: Simple Image filter by width/height (size)

Post by mapx »

1. || is available only for the blocking filters not for hiding ones
2.if the source / page does not contain the width selector you can't do it
asimo
Posts: 3
Joined: Fri Apr 24, 2015 5:05 pm

Re: Simple Image filter by width/height (size)

Post by asimo »

Ok, so I need to target the image by the position or complete filename. Thats ok for me.

Thank you for your help!
Locked