gonzai.com

Posting here is no longer possible, please use the forum of a filter list project, such as EasyList
Locked
User avatar
smed79
Posts: 1224
Joined: Thu Jan 14, 2010 11:51 pm
Location: EasyList Forum
Contact:

gonzai.com

Post by smed79 »

Hello,
wath filter can i use hide background element link to ad.doubleclick.net/... ?

on http://gonzai.com/
lewisje
Posts: 2743
Joined: Mon Jun 14, 2010 12:07 pm

Re: gonzai.com

Post by lewisje »

I think you'll need a UserScript, to disable the click-handler for the section element with id main or its sole child, the div element with class main-container.

The link destination, and probably the background image, are already blocked by various lists, but the section or div cannot be hidden without also hiding all of the page content.

I can imagine something like this as a quick and dirty hack, which will surely make the layout horrible:

Code: Select all

var main = document.getElementById('main'), content = main.firstChild.innerHTML, footer = document.getElementById('footer-container'), wrapper = main.parentNode, newmain = document.createElement('div');
newmain.innerHTML = content;
wrapper.removeChild(main);
wrapper.insertBefore(newmain, footer);
A better idea would be to see where the click-handler gets set and then, in your UserScript, explicitly call removeEventListener, something like document.getElementById('main').removeEventListener('click', <adPopup>, false); where <adPopup> is the name of a function that launches the popup ad; if it's an anonymous function expression, as is common with event handlers, you could try to modify my earlier hack to re-generate the relevant styles.

---

TL;DR I guess you can't get rid of that with ABP after all: You can block where the links go to but you can't get rid of the clickable area without hiding the content.
There's a buzzin' in my brain I really can't explain; I think about it before they make me go to bed.
User avatar
smed79
Posts: 1224
Joined: Thu Jan 14, 2010 11:51 pm
Location: EasyList Forum
Contact:

Re: gonzai.com

Post by smed79 »

lewisje wrote:The link destination, and probably the background image, are already blocked by various lists
https://hg.adblockplus.org/listefr/rev/4804688704ee

Ok; thank you for your help.
Locked