sitexw / blockadblock Goto Github PK
View Code? Open in Web Editor NEWAllows you to detect the extension AdBlock (and other)
Home Page: http://fuckadblock.sitexw.fr/blockadblock/
License: MIT License
Allows you to detect the extension AdBlock (and other)
Home Page: http://fuckadblock.sitexw.fr/blockadblock/
License: MIT License
Anti ad block killer has made blockadblock useless:( what can I do?
Sites that have generichide and elementhide filters don't get detected. Is there some way to detect these sites?
gfys
does not work with this adblockr
i want to display a special div depending on whatever adBlock is detected or not (in both case, i must passthru a function in other to make other things like logs, etc ). But the problem is when i use blockAdBlock.on(true, {function1}); blockAdBlock.on(false, {function2}); {function1} is still executed. Is there a way to not execute my {function1} if blockAdBlock.on is FALSE ?
if(typeof blockAdBlock === 'undefined') {
testIfUserFromFrance(); /* display div1|div2, if from France or Not */
} else {
blockAdBlock.on(true , testIfUserFromFrance() ); /* display div1|div2, if from France or Not */
blockAdBlock.on(false, adBlockDefault); /* display the div3, if AdBlock is false (default beheavior) */
}
Hello,
When trying this link https://fuckadblock.sitexw.fr/blockadblock/ (3.2.1):
-> AdBlock is always detected as enabled even without any AdBlocker installed or turned OFF.
When trying this link https://fuckadblock.sitexw.fr/ (3.2.1):
-> AdBlock is always detected as disabled with AdBlocker installed and turned ON.
Tried with last versions of Chrome, Safari and Firefox.
Any suggestions?
Thanks.
Is just me, or this page : https://fuckadblock.sitexw.fr/blockadblock/ with https://getadblock.com/ -> Version 4.22.1
Doesn't work properly?
With chrome dev it works.
chrome Version 85.0.4183.121
chrome Chromium
Both don't work....
Hi, is there a way to detect also uBlock Origin, are you planning to make an updated version in the near future? Thank your for your work.
I am calling website A from website B in a hidden iframe, i have adblock checks in that hidden iframe and even though i have disabled adblocks it says they are active. Is there a way to fix this?
The fair adblock on chrome is not working.
Does it work when implemented using webview in an android app?
From looking at the errors in our Sentry setup I can see that there are cases where the bait has already been removed by someone before the library calls the _destroyBait
method here:
Line 94 in bf4c340
Failed to execute 'removeChild' on 'Node': The node to be removed is not a child of this node.
Since the library theoretically emits the events after removing the bait, this will never happen in case the above throws.
Ideally the library would simply check if the bait is still in the DOM before trying to remove it.
window.devicePixelRatio
window.devicePixelRatio == 1
then zoom out to 33% and refresh page.
window.devicePixelRatio > 1
(i.e. testing on a retina screen) zoom level and window dimensions may differ slightly to above.The above steps mean this._var.bait.offsetHeight
, this._var.bait.offsetWidth
, this._var.bait.clientHeight
, this._var.bait.clientWidth
all equal zero and flag detected.
Within Safari on MacOs with Addblock plus is not detected by the script.
Verified to happen on the demo page: http://fuckadblock.sitexw.fr/blockadblock/
You can bypass it by installing this unpacked extension:
https://github.com/nathan-149/adblock-extension-nodetect
This is an undetectable adblocker
Visiting your demo link (https://fuckadblock.sitexw.fr/blockadblock/) with Adblock Plus enabled, it does not detect the adblocker any more. This appears to have changed in the last couple of days.
All of my applications using blockadblock are experiencing the same problem.
Calling the check
method on either the default blockAdBlock
instance, or on a newly instantiated instance, will always return true
, whether AdBlock is paused or unpaused. Why is that?
AdBlock for Mac Chrome version 3.8.4
Chrome for Mac version Version 55.0.2883.95
Mac OS X "El Capitan" (10.11.6)
Tested with Ka-Block! on OSX with Safari, ad blocking not detected.
I think it is misleading that it is called blockadblock if it does not block adblock.
Thanks for reading!
By the way great script!
Using Adblock Chrome 51 OS X 10.11.5 is detected when it's paused as well, which seems to be fixed in v4 beta.
Hey there.. first i want to say that your script is exactly what im looking for but, in my case it wont work as expected.
It blocks / replaces one entry fine but as soon as i add a secound id="..." to check again it fails..
testet the same behaviour on your site, seems like you cant have multiply requests at the same time..
(in my example i have 4 ads in a row that should be replaced with other images as soon as adb is detected, first one works fine, the other 3 get ignored)
what can i do?
If I visit the online example page, the page correctly displays the status of my ad blocker.
However if I pause the ad blocker and click the example page's "check again" button, the previous status is repeated.
Software versions:
AdBlock for Mac Chrome version 3.8.4
Chrome for Mac version Version 55.0.2883.95
Mac OS X "El Capitan" (10.11.6)
Console logs:
blockadblock.js:57 [BlockAdBlock][setOption] The option "debug" he was assigned to "true"
blockadblock.js:57 [BlockAdBlock][on] A type of event "detected" was added
blockadblock.js:57 [BlockAdBlock][on] A type of event "notDetected" was added
blockadblock.js:57 [BlockAdBlock][onload->eventCallback] A check loading is launched
blockadblock.js:57 [BlockAdBlock][_creatBait] Bait has been created
blockadblock.js:57 [BlockAdBlock][check] An audit was requested with a loop
blockadblock.js:57 [BlockAdBlock][check] A check is in progress ...
blockadblock.js:57 [BlockAdBlock][_checkBait] A check (1/5 ~1ms) was conducted and detection is positive
blockadblock.js:57 [BlockAdBlock][_stopLoop] A loop has been stopped
blockadblock.js:57 [BlockAdBlock][_destroyBait] Bait has been removed
blockadblock.js:57 [BlockAdBlock][emitEvent] An event with a positive detection was called
blockadblock.js:57 [BlockAdBlock][emitEvent] Call function 1/1
blockadblock.js:57 [BlockAdBlock][clearEvent] The event list has been cleared
// Pausing AdBlock and re-checking...
undefined
blockadblock.js:57 [BlockAdBlock][on] A type of event "detected" was added
blockadblock.js:57 [BlockAdBlock][on] A type of event "notDetected" was added
blockadblock.js:57 [BlockAdBlock][check] An audit was requested with a loop
blockadblock.js:57 [BlockAdBlock][_creatBait] Bait has been created
blockadblock.js:57 [BlockAdBlock][check] A check is in progress ...
blockadblock.js:57 [BlockAdBlock][_checkBait] A check (1/5 ~1ms) was conducted and detection is positive
blockadblock.js:57 [BlockAdBlock][_stopLoop] A loop has been stopped
blockadblock.js:57 [BlockAdBlock][_destroyBait] Bait has been removed
blockadblock.js:57 [BlockAdBlock][emitEvent] An event with a positive detection was called
blockadblock.js:57 [BlockAdBlock][emitEvent] Call function 1/1
blockadblock.js:57 [BlockAdBlock][clearEvent] The event list has been cleared
const adsEnabled = async () => {
let ads = true;
try {
const url = `https://ads.google.com?=${new Date().getTime()}`;
await fetch(url, { mode: "no-cors" });
} catch (error) {
if (error.message === "Failed to fetch") {
ads = false;
}
}
return ads;
};
// check
const isAdEnabled = await adsEnabled();
console.log(isAdEnabled);
just wondering if it possible to return a simple true|false statement on test... it may be simplier to integrate with already custom js script.
example :
if(typeof blockAdBlock === 'undefined') {
adb = 0; /* 0 = false */
} else {
adb = blockAdBlock.toggleTestReturn(); /* return 0 or 1 */
}
The BlockAdBlock would detect correctly only when page refresh.
I turn on and off adblock after a while, BlockAdBlock cannot detect.
It suppose to detect the correct result whenever I call BlockAdBlock.check()
The script claims Adblock is enabled even if it has been disabled for the specific page or even the whole domain. Seems specific to Firefox with Adblock Plus. Tested in Firefox 42 with Adblock Plus 2.7 on both MacOS and Windows 7.
Verified to happen on the demo page: http://fuckadblock.sitexw.fr/blockadblock/
Just curios if you are the creator of https://blockadblock.com/, and or if this project is based off BlockAdBlock or FuckAdBlock Project.
Bonjour!
You've still got bower install fuck-adblock
on your demo site. Awesome lib, look forward to using and contributing!
I tested the demo page with Cliqz Browser and it seems that this adblocker does not get detected from the script?
Important notice,
that blockadblock.js
is not blocked bacause it's not in the easylist (check https://easylist-downloads.adblockplus.org/easylist.txt).
However, the script named fuckadblock.js
script gets blocked when Adblock & ABP is present in users' browser!
Unfortunately, fuckadblock.js is not so convenient name in production code, but you can use a js file called abdetect.js
instead.
what about adblocker ultimate on firefox?!! :(
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.