Giter Site home page Giter Site logo

Comments (8)

sitexw avatar sitexw commented on July 18, 2024

It is normal that it will start the detection process again if you call the "check" method again.
But I'm afraid I did not understand the problem.

from blockadblock.

 avatar commented on July 18, 2024

If I have AdBlock unpaused, and I visit the online example, the page correctly displays "AdBlock is enabled". However, if I then pause AdBlock and click the "Check again" button, the page still reports "enabled", whereas I would expect it now to report "not enabled".

Similarly, if I have AdBlock paused, and I visit the online example, the page correctly displays "AdBlock is not enabled". However, if I then unpause AdBlock and click the "Check again" button, the page still reports "not enabled", whereas I would expect it now to report "enabled".

from blockadblock.

sitexw avatar sitexw commented on July 18, 2024

Ok, I had not understood the notion of "pause" (to disable AdBlock).

In this case, it is not the responsibility of BlockAdBlock, because disabling AdBlock (via its menu) will really disable it only after the page is reloaded.

For example, you can try to display ads after 30 seconds after the page loads and in the meantime disable AdBlock, you will see that the ads will still be blocked. Because for the deactivation to be really effective, you have to reload the page.

from blockadblock.

 avatar commented on July 18, 2024

…disabling AdBlock (via its menu) will really disable it only after the page is reloaded…

This is technically not true. As soon as AdBlock is paused, it stops blocking ad-related content.

We have noticed that AdBlock causes failure on invocations of our in-house API call to save a form's data. This is not on a public page, and the page has no ads. Refreshing the page would not be an option, because form data would then be lost.

Toggling AdBlock off prevents that API error, so I was hoping to be able to detect and re-detect the status of our users' ad blockers.

from blockadblock.

 avatar commented on July 18, 2024

I have also tried deleted and re-instantiating the BlockAdBlock object and forcing a re-check. But it continually reports the original state, rather than the updated state.

Is there some other way to re-check that I'm missing? Why have a re-check button at all?

Thank you.

from blockadblock.

sitexw avatar sitexw commented on July 18, 2024

To be exact, AdBlock is partially disabled.
That is, the detection of advertisements by the DOM (HTML) is still functional, but the interception of HTTP requests is disabled. As the V3 of BlockAdBlock works with detection by the DOM, this is why it continues to detect AdBlock.

For your particular case, it would be necessary to set up an HTTP detection. I propose 2 solutions either you realize this detection yourself by detecting the blocking of the sending of your form, or you use the V4 of FuckAdBlock with only the detection by HTTP.

from blockadblock.

 avatar commented on July 18, 2024

I see. Thank you.

from blockadblock.

sitexw avatar sitexw commented on July 18, 2024

To use the V4, I advise you to instantiate yourself :
https://fuckadblock.sitexw.fr/beta/#Instance_222
And to run the "check" manually with only HTTP detection:

myFuckAdBlock.check(['http']);

But AdBlock can put a sticks in the wheels, blocking the FuckAdBlock script, preventing you from manual instantiation and "check".

from blockadblock.

Related Issues (20)

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.