Writing ABP filters: ~elemhide and ~document

Discussion on adblockplus.org website and translations

Writing ABP filters: ~elemhide and ~document

Postby famlam » Sun Nov 21, 2010 12:11 am


Just wondering:
Your website tells me this (http://adblockplus.org/en/filters):
Inverse type options: specify the element types the filter should not be applied to. Possible inverse type options: ~script, ~image, ~background, ~stylesheet, ~object, ~xbl, ~ping, ~xmlhttprequest, ~object-subrequest, ~dtd, ~subdocument, ~document, ~elemhide, ~other

however, $document and $elemhide have no inverse, do they?

At least:
@@*$~document is treated as @@*
@@*$~elemhide is treated as not_existing
Posts: 59
Joined: Sat Aug 07, 2010 2:06 pm

Re: Writing ABP filters: ~elemhide and ~document

Postby Wladimir Palant » Wed Nov 24, 2010 4:52 pm

@@*$~document will whitelist URLs but not entire documents - e.g. @@|http://www.google.com/$~document will whitelist everything loaded by Google search but won't disable Adblock Plus on that page (so that third-party requests might still be blocked).

As to $~elemhide - it is pretty useless because $elemhide option isn't implied by default, you have to specify it explicitly. But $image,elemhide,~elemhide is valid - even though it is equivalent to $image.
Wladimir Palant
ABP Developer
Posts: 8397
Joined: Fri Jun 09, 2006 6:59 pm
Location: Cologne, Germany

Return to Website and translations

Who is online

Users browsing this forum: Google [Bot] and 1 guest