Page 2 of 3

Posted: Tue Dec 16, 2008 6:27 pm
by Wladimir Palant
I don't see $url= being implemented, this would significantly overcomplicate things. Generally, if we do that pipes won't be the only problem - regular expression can contain just about anything. So we either say that $url must always be the last option and everything that follows is its value or we say that the value must be put in quotation marks if it has any special characters.

Posted: Tue Dec 16, 2008 8:16 pm
by Adblock Plus Fan
Wladimir Palant wrote:I don't see $url= being implemented
Then the current syntax seems pretty good to me. I don't see any problems with
foo.com/ad$domain=foo.com|bar.com|~baz.bar.com


Anyway, I've been thinking a little about making it look like element hiding rules with comma separation.
What if we took Rick's example:

Code: Select all

google-analytics$domain=~a.com|~b.com|~c.com
And made it like this:

Code: Select all

google-analytics$@@a.com,@@b.com,@@c.com
Would it be feasible from a performance standpoint to separate each domain exemption/restriction into its own filter option?

This way they would reminiscence of the real whitelists, and they would be separated by comma like element hiding rules too.

But then the inverse ($domain=foo.com) would have to look like $@@~foo.com.

I have no idea if this is sensible at all though... Just brainstorming.

Posted: Tue Dec 16, 2008 9:16 pm
by Wladimir Palant
One problem is - we can only drive the analogy to element hiding so far. In the end we cannot have domain exceptions in element hiding rules. But people will expect that it should work for element hiding rules if the syntax is the same.

But the other question is: if we make $@@foo.com an exception for a single domain we need similar syntax to include a domain. I don't see anything that would be easy to recognize/understand.

Posted: Wed Dec 17, 2008 7:22 am
by Wladimir Palant
That seems to be another application: http://adblockplus.org/forum/viewtopic.php?t=3278
I can imagine filters like "*$object,domain=~foo.com|~bar.com"

Posted: Wed Dec 17, 2008 1:39 pm
by Ares2
Another request I've seen some times is to only use ABP on pages that deserve it (= use really annoying ads).

This would work with

Code: Select all

@@*$domain=~annoy.com|~usinglayerads.com
in addition to a filter subscription.

Posted: Wed Dec 17, 2008 1:51 pm
by SlimShady
It does make the filter(s) crowded. Personally I'd rather have a per-domain filter group.
But I'm fine with this if it helps the filter subscriptions. Making it more efficient.

Posted: Wed Dec 17, 2008 2:11 pm
by Wladimir Palant
@Ares2: Actually, better this one:

Code: Select all

@@*$document,domain=~annoy.com|~usinglayerads.com
That will entirely disable ABP (including element hiding) on all sites but the ones specified. Nice indeed, this is definitely worth implementing.

Posted: Fri Dec 19, 2008 12:50 pm
by anklebone
I think this would be very useful. Specifically, I'd like to be able to to block certain third-party javascript (and images etc) from loading on all sites, except for those that I've specifically allowed.

I imagine the interface being similar to that of NoScript, allowing the user to easily choose certain things that should be allowed to load on the current domain/subdomain/url.

Posted: Fri Dec 19, 2008 5:46 pm
by Adblock Plus Fan
anklebone wrote:I think this would be very useful. Specifically, I'd like to be able to to block certain third-party javascript (and images etc) from loading on all sites, except for those that I've specifically allowed.
Indeed. Say We have this filter:

Code: Select all

*$third-party,script
This should be pretty much the equivalence of the Noscript setting "Temporarily allow top-level sites by default".
You could do something like this:

Code: Select all

*$third-party,script$domain=~a.com
This is suboptimal though, since it allows all 3rd party scripts on that site.

There might be a situation where the site has 3rd party scripts from 10 different parties, and we only want to allow one.
Then we can do this:

Code: Select all

@@google-analytics$script,domain=a.com
So we'll have the capability to lock the allowance to only the sites we have permitted.

This is superior to what Noscript currently is able to do:

Code: Select all

@@google-analytics$script
So if a website has strong-armed you into allowing a script, you would be forced to allow this script for all sites in Noscript.
But with ABP, we can keep the damage to a minimum and only allow the script for that 1 particular site. This is way better than what's currently possible in Noscript.

Posted: Fri Dec 19, 2008 6:16 pm
by anklebone
Adblock Plus Fan wrote: There might be a situation where the site has 3rd party scripts from 10 different parties, and we only want to allow one.
Then we can do this:

Code: Select all

@@google-analytics$script,domain=a.com
So we'll have the capability to lock the allowance to only the sites we have permitted.

This is superior to what Noscript currently is able to do:

Code: Select all

@@google-analytics$script
So if a website has strong-armed you into allowing a script, you would be forced to allow this script for all sites in Noscript.
But with ABP, we can keep the damage to a minimum and only allow the script for that 1 particular site. This is way better than what's currently possible in Noscript.
Yes, that sounds perfect.

Posted: Fri Dec 19, 2008 11:32 pm
by rick752
This filtering flexibility will be unsurpassed by ANYTHING out there right now. There will also be some techniques used by some sites that will become worthless.

I can't wait for this option to become mainstream. It will certainly keep the filter guys busy with new ideas for rules :)

The recent options are exciting stuff :mrgreen:

Re:

Posted: Sat Dec 20, 2008 2:27 pm
by smk
I always thought customized-lists would be good, and maybe they can come here
rather than separating things by ","
why not make a sub-list to the rule?

Code: Select all

@@*$document,domain
    -domain options:
        @@annoy.com
        @@usinglayerads.com
        @@/annoy\d+/
yeah, all this is getting amazing :)
I hope the next-thing to do is implement html-blocking when firefox 3.1 comes out :)

Posted: Sat Dec 20, 2008 3:33 pm
by Dipole Moment
smk wrote: I hope the next-thing to do is implement html-blocking when firefox 3.1 comes out :)
Don't forget XML and JS...

Posted: Sun Dec 21, 2008 4:42 am
by Wladimir Palant
This is mostly done now: http://hg.mozdev.org/adblockplus/rev/c6ee27f5595d

I still need to add some help text to filter composer to explain the format. I also want a context menu entry "Disable/re-enable filter on foo.com" in blockable items (for user-defined filters only) but that will take somewhat longer - won't be in the next development build.

Posted: Tue Dec 23, 2008 12:41 am
by chris
when do site specific filters go live and not jsut developmental builds?