Ad blocker - how to remove ad space?

I'm currently building an ad blocker (yes, another one). How do I configure it to remove the spaces where ads appear?

Replies

I don't think you can.


The white space depends on how the web page has been built - some put space aside for the ad (eg. a div with dimensions, which stays even if the ad is not there) and others grow space for the add image (eg. a div without dimensions, which disappears when the ad is removed).

Check out the WWDC '15 511 track. They show an example of using a css rule for display none on a paraticular selector.



{
     "action": {
          "type": "css-display-none",
          "selector": "#links" 
     },
     "trigger": { 
          "if-domain": ["bigbearsgolfblog.com"], 
          "url-filter": ".*"
     } 
}


This will hide div <div id="links"> element. Hope that helps