Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $('.popen').hide();
- $('.pclose').show();
- var modal = document.getElementById('small_modal');
- var largeModal = document.getElementById('large_modal');
- function checkAds() {
- var ads = document.querySelectorAll('.adsbygoogle');
- var emptyAds = false;
- for (var i = 0; i < ads.length; i++) {
- if(ads[i].getAttribute('data-ad-status') === 'unfilled'){
- ads[i].removeAttribute('data-adsbygoogle-status');
- ads[i].removeAttribute('data-ad-status');
- ads[i].removeAttribute('data-ad-slot');
- ads[i].removeAttribute('data-ad-client');
- ads[i].innerHTML = '';
- (adsbygoogle = window.adsbygoogle || []).push({});
- console.log('Ad regenerated!');
- }
- }
- }
- setInterval(checkAds, 3000);
- function regenerateAds() {
- var ads = document.querySelectorAll('.adsbygoogle');
- for (var i = 0; i < ads.length; i++) {
- ads[i].removeAttribute('data-adsbygoogle-status');
- ads[i].removeAttribute('data-ad-status');
- ads[i].removeAttribute('data-ad-slot');
- ads[i].removeAttribute('data-ad-client');
- ads[i].innerHTML = '';
- (adsbygoogle = window.adsbygoogle || []).push({});
- console.log('Ad regenerated!');
- }
- }
- setInterval(regenerateAds, 120000);
- function showCustomPopup() {
- var customPopup = document.getElementById('custom-popup');
- customPopup.style.display = 'flex';
- customPopup.style.zIndex = '999';
- var blurElement = document.createElement('div');
- blurElement.setAttribute('id', 'blur');
- blurElement.style.position = 'fixed';
- blurElement.style.top = '0';
- blurElement.style.left = '0';
- blurElement.style.width = '100%';
- blurElement.style.height = '100%';
- blurElement.style.backgroundColor = 'rgba(0, 0, 0, 0.5)';
- blurElement.style.zIndex = '998';
- blurElement.style.backdropFilter = 'blur(5px)';
- document.body.appendChild(blurElement);
- }
- function hideCustomPopup() {
- var customPopup = document.getElementById('custom-popup');
- customPopup.style.display = 'none';
- customPopup.style.zIndex = '0';
- var blurElement = document.getElementById('blur');
- blurElement.parentNode.removeChild(blurElement);
- }
- function adBlockDetected() {
- showCustomPopup();
- }
- if (typeof blockAdBlock === 'undefined') {
- adBlockDetected();
- }
- setTimeout(function() {
- document.getElementById('my-vignette-ad').style.visibility = 'visible';
- }, 300000);
- });
- function hideVignetteAd() {
- document.getElementById('my-vignette-ad').style.visibility = 'hidden';
- setTimeout(function() {
- document.getElementById('my-vignette-ad').style.visibility = 'visible';
- }, 600000);
- }
- hideTopAd = function() {
- $('#top_ad_close').slideUp(100);
- $('#special_space').slideUp(100);
- setTimeout(function() {
- $('#special_space').slideDown(100);
- setTimeout(function() {
- $('#top_ad_close').slideDown(100);
- }, 2500);
- }, 90000);
- event.stopPropagation();
- }
- hidePrvTopAd = function() {
- $('#prvtop_ad_close').hide();
- $('#prv_special_space').slideUp(100);
- setTimeout(function() {
- $('#prv_special_space').slideDown(100);
- setTimeout(function() {
- $('#prvtop_ad_close').show();
- }, 2500);
- }, 90000);
- event.stopPropagation();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement