Page 1 of 1

How can I block images that refer to special site

Posted: Fri Apr 11, 2008 3:33 pm
by BrainWorker
How can I block images that refer to special site?

For example, many sites have some blocks (at top or bottom or anywhere else) for advertisement of special source.
In this case, the code is something like this

Code: Select all

<a href="some-source-of-ads.com"><img src="any-image-address-different-all-the-time.gif"></a>
How can I write filter rule to block all the images that refer to special web site?

Thanks

Posted: Fri Apr 11, 2008 3:39 pm
by rick752

Posted: Fri Apr 11, 2008 3:50 pm
by BrainWorker
Thanks.

You wrote
rick752 wrote:Element-hiding rules for link blocking work MUCH better and do more too. Simply adding a rule like:

Code: Select all

#a(href*=badlink.com)
..not only hides any image or flash link to that domain, but also will hide any plain text links to that site too. :wink:
As I understand
a - name of tag defining block to block (sounds great :) )
href - its attribute

But what does asterisk mean right after "href" ?

Posted: Fri Apr 11, 2008 3:57 pm
by rick752
BrainWorker wrote:Thanks.

You wrote
rick752 wrote: But what does asterisk mean right after "href" ?
That is a wildcard for the link address so you don't have to write the full link address ... eg: "http://www.badlink.com/something/something.htm"

Without the * , it would not work with my example.