<script>/*<![CDATA[*/
/**
*/
(function(key){const data={allowed:null},url="https://cdn.jsdelivr.net/gh/fineshop/plus-ui@2.7.0/main/ads/adsbygoogle.js";this[key]=function(callback){if("function"!=typeof callback)return;const called=[];function oneTimeCallback(){0===called.length&&(called.push(1),callback(data))}if("boolean"!=typeof data.allowed){let xhr=null;try{xhr=new XMLHttpRequest}catch(e){try{xhr=new ActiveXObject("Msxml2.XMLHTTP")}catch(e){try{xhr=new ActiveXObject("Microsoft.XMLHTTP")}catch(e){return}}}xhr.onreadystatechange=function(){if(xhr.readyState===xhr.DONE){if(xhr.status>=200&&xhr.status<=299){const fakeAd=document.createElement("div");fakeAd.className="textads banner-ads banner_ads ad-unit ad-zone ad-space adsbox ads",fakeAd.style="height: 1px; width: 0; opacity: 0; visibility: hidden; position: fixed; bottom: 0",document.body.appendChild(fakeAd),data.allowed=0!==fakeAd.offsetHeight,fakeAd.remove()}else data.allowed=!1;oneTimeCallback()}},xhr.onerror=function(){data.allowed=!1,oneTimeCallback()},xhr.open("GET",url),xhr.send("")}else oneTimeCallback()}}).call(this,"checkAdsStatus");
function antiAdBlockerHandler() {
window.checkAdsStatus(function(ads) {
if (!ads.allowed) {
// Ads are Blocked
console.log("%c[ADS]", "color:#d32f2f;", "Blocked");
const icon = "<svg style='stroke:none;fill:currentColor!important' viewBox='0 0 24 24'><path d='M12.2 9L10.2 7H13C14.1 7 15 7.9 15 9V11.8L13 9.8V9H12.2M23 9V7H19C17.9 7 17 7.9 17 9V11C17 12.1 17.9 13 19 13H21V15H18.2L20.2 17H21C22.1 17 23 16.1 23 15V13C23 11.9 22.1 11 21 11H19V9H23M22.1 21.5L20.8 22.8L14.4 16.4C14.1 16.7 13.6 17 13 17H9V10.9L7 8.9V17H5V13H3V17H1V9C1 7.9 1.9 7 3 7H5.1L1.1 3L2.4 1.7L22.1 21.5M5 9H3V11H5V9M13 14.9L11 12.9V15H13V14.9Z'/></svg>";
const title = "Ad blocker detected!";
const message = "<p>We have detected that you are using adblocking plugin in your browser.<br/>The revenue we earn by the advertisements is used to manage this website, we request you to whitelist our website in your adblocking plugin.</p>";
// Lets create the popup
const element = document.createElement("div");
element.className = "popSc";
element.innerHTML = "<div class='popBo'>" + icon + "<h2>" + title + "</h2><div class='popCo'>" + message + "</div></div>"
document.body.appendChild(element);
} else {
// Ads are allowed;
console.log("%c[ADS]", "color:#43a047;", "Allowed");
}
});
document.removeEventListener("DOMContentLoaded", antiAdBlockerHandler);
};
if (document.readyState === "complete" || document.readyState !== "loading") {
antiAdBlockerHandler();
} else {
document.addEventListener("DOMContentLoaded", antiAdBlockerHandler);
}
/*]]>*/</script>
Comments
Post a Comment