Code Monkey home page Code Monkey logo

Comments (2)

fivefilters avatar fivefilters commented on August 18, 2024 1

Thank you for the kind words. :)

It is possible to do this. In fact, we do it on FiveFilters.org. If a visitor to our site does not have ad blocking enabled, they will see a link in the top navigation to our Block Ads! site. If they do, that link will not display.

We've been meaning to make a simple cut and paste HTML snippet for this purpose. For the time being you can use what's posted here: https://forums.lanik.us/viewtopic.php?f=85&t=30824 Inserting the CSS block and HTML block in your site should do the job. Although we generally do not recommend Adblock Plus. So I would change the URL and link text to either point to uBlock Origin or our Block Ads! site (uBlock Origin does not yet have a nice home page to tell the user which version of their application they need to install).

When I get some time, I will try and do a version based on this to promote uBlock Origin instead and I'll post it here.

If you're curious about how this works, the key part of the method above is the inclusion of the class attribute value "GoogleAd":

<div class="abp-box abp-msg GoogleAd">Install...

Ad blockers that rely on Easy List (e.g. AdBlock Plus, uBlock Origin and many others) will see that as a sign that what it holds is an ad, and so they won't show it. Users who don't have an ad blocker will see the contents, which in this case is not an ad, but a message to install an ad blocker.

from block-ads.

hdkw avatar hdkw commented on August 18, 2024

Thanks for your answer, this is great and I'm looking forward for your snippet. How can I contact you privately by the way ?

from block-ads.

Related Issues (11)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.