views:

93

answers:

3

I wish to block ALL my content from any users using an ad-blocking browser extension (ie. Adblock Plus for Firefox, Adthwart for Chrome).

How can I acheive this? Is there a server-side solution? Client-side?


Edit 1 This question regards the detection of ad-blocking browser extensions:

http://stackoverflow.com/questions/1185067/detecting-adblocking-software

I'm concerned with post-detection action.


Edit 2 A duplicate question was asked after mine, so I thought I'd link to it here:

http://stackoverflow.com/questions/2002403/prevent-adblock-users-from-accessing-website

A: 

That I know of this is not directly possible. Most add blockers work by locking at the URLs that are being "requested" and either blocking directly, or looking at the content/mime-type and blocking based on that.

You might be able to do something by looking for signs of the adblocker, but this will be difficult at best.

GrayWizardx
A: 

Although I love my adblocker, it's about answering questions. You could check if an url that would normally be blocked by an adblocker is reachable, and continue only if that image/bla in question is loaded. otherwise, you just don't.

moritz
A: 

It's like trying to block users from reading your contents while standing rather then while sitting. It's silly, and it's likely to drive visitors off your site. The last time i saw a "you're using adblock, that hurt web developing bla bla" i jst blocked that div with the element hiding helper. It was fun i admit. Most sites are almost unreadable as now, with flashing ads and pale contents. A good quantity of ads are, also, malevolent, disguised as part of the site they're in takes the user to bad places.

That's why you should not. If you still want to, bad news, you can't. As long as i can write $('.ad').hide() in my console, nobody can stop me from adblocking something. I sometimes give up when ads divs have a very generic class, id, or they haven't any, so that it's difficult to target them with the adblock element hiding helper (of course if they are not in the lists, in that case i dont even know they exists). So the best you can do probably is give to ads a class of .content or something you use also in other parts of the site. It's not much, but it' all you can do. And just because you can, it does not mean you should. The web marketing model have to change, and it will.

Marek