Οδηγίες προστασίας για να μη βρεθείς πρόωρα γερασμένη.
500 ){ slotSkin = googletag.defineSlot('/'+ dfpAccountId +'/shape_skin', [1, 1], 'div-shape-skin').addService(googletag.pubads()); } slotShapeInread = googletag.defineSlot('/'+ dfpAccountId +'/Shape_inread', [1, 1], 'div-inread').addService(googletag.pubads()); slotShapeInreadAdx = googletag.defineSlot('/3346429/InRead_infeed_shape_AdX', [[400, 300], [300, 250], [300, 600], [640, 480]], 'div_infeed').addService(googletag.pubads()); slotWebover_out_of_page = googletag.defineOutOfPageSlot('/'+ dfpAccountId +'/shape_webover_out-of-page', 'div-gpt-ad-out-of-page').addService(googletag.pubads()); googletag.pubads().setTargeting('ksg', Krux.segments); googletag.pubads().setTargeting('kuid', Krux.user); googletag.pubads().setTargeting('page', targetCriteria).setTargeting("pagetype", pageType); console.log("TargetCriteria:"+ targetCriteria); console.log("PageType:" +pageType); //googletag.pubads().enableSingleRequest(); //googletag.pubads().disableInitialLoad(); googletag.pubads().collapseEmptyDivs(); //googletag.pubads().enableSyncRendering(); googletag.pubads().enableLazyLoad({ fetchMarginPercent: 200, // Fetch slots within 2 viewports. renderMarginPercent: 100, // Render slots within 1 viewports. mobileScaling: 1.0 // dont Double the above values on mobile. }); googletag.enableServices(); if(window.innerWidth>1172){ googletag.pubads().addEventListener('impressionViewable', function(event) { if (event.slot == slot300x250A ) { console.log( 'Va' ); setTimeout( function () { googletag.pubads().refresh([slot300x250A]); console.log( 'A2' ); }, 30000); } if (event.slot == slot300x250B ) { console.log( 'Vb' ); setTimeout( function () { googletag.pubads().refresh([slot300x250B]); console.log( 'B2' ); }, 30000); } }); } googletag.pubads().addEventListener('slotRenderEnded', function(event) { if ( (event.slot.getAdUnitPath() === '/' + dfpAccountId + '/shape_skin') || (event.slot.getAdUnitPath() === '/' + dfpAccountId + '/shape_skin_minipage') ) { var eventSize = (-1 * event.size[0] / 2); console.log( event.isEmpty ); console.log( event.size[0] ); console.log( event.size[0] ); if (!event.isEmpty ){ document.body.className += " enableskin"; skinEmpty = false; document.getElementById('div-shape-skin-container').style.marginLeft = ( eventSize + 0 ) + 'px'; } } if(event.slot.getAdUnitPath() === '/' + dfpAccountId + '/shape_728*90') { align2device( 'dfp_728_90_A', event ); if ( window.innerWidth < 640 ) { stickyFirstBannerFn(); } } if(event.slot.getAdUnitPath() === '/' + dfpAccountId + '/shape_728*90_B') { align2device( 'div-gpt-ad-1485434231108-0', event ); } if(event.slot.getAdUnitPath() === '/' + dfpAccountId + '/Shape_990x90') { containsAd = 1; isexpand = 0; adShrinkToFit(containsAd, event, "header-banner2" , "header-banner2-inner" , isexpand); document.getElementById('header-banner2').style.display = 'block' ; document.getElementById('header-banner2-inner').style.webkitTransformOrigin = 'left top' ; document.getElementById('header-banner2-inner').style.MozTransformOrigin = 'left top' ; document.getElementById('header-banner2-inner').style.msTransformOrigin = 'left top' ; document.getElementById('header-banner2-inner').style.OTransformOrigin = 'left top' ; document.getElementById('header-banner2-inner').style.transformOrigin = 'left top' ; } function adShrinkToFit(containsAd, event, adMainContainerID, adInnerContainerID, isexpand) { var adcontainer = document.getElementById(adMainContainerID); var adcontainerParent = document.getElementById(adMainContainerID).parentElement; var billboards = document.getElementById(adInnerContainerID); if (containsAd == true) { var screenwidth = window.innerWidth; var shrinkpercent = 0; var adwidth = event.size[0]; var adheight = event.size[1]; var adminheight = event.size[1]; //Ελεγχος εαν η διαφήμιση είναι μεγαλύτερη του window size //και υπολογισμός του zoom if (adwidth > screenwidth) { shrinkpercent = Math.round((screenwidth * 100) / adwidth) billboards.style.padding = "0"; billboards.style.position = "relative"; billboards.style.display = "block"; billboards.style.webkitTransform = "scale(0." + shrinkpercent + ")"; billboards.style.MozTransform = "scale(0." + shrinkpercent + ")"; billboards.style.msTransform = "scale(0." + shrinkpercent + ")"; billboards.style.OTransform = "scale(0." + shrinkpercent + ")"; billboards.style.transform = "scale(0." + shrinkpercent + ")"; //billboards.style.transformOrigin = 'top center' ; } //Container Height if (shrinkpercent != 0) { adminheight = Math.round((adheight * shrinkpercent) / 100); } if (isexpand != 1) { adcontainer.style.height = (adminheight + 10) + "px"; } else { adcontainer.style.height = "auto"; } } else { adcontainer.style.display = "none"; adcontainerParent.style.display = "none"; } } // sticky first banner function stickyFirstBannerFn() { var fired = false; // var stickBanner = window.addEventListener( "scroll" , function () { // if (fired === false ) { var scrollTop = (window.pageYOffset !== undefined) ? window.pageYOffset : (document.documentElement || document.body.parentNode || document.body).scrollTop; // if (scrollTop >= 50 && fired === false ) { if (fired === false ) { jQuery( "#dfp_728_90_A" ).css( "position" , "fixed" ); jQuery( "#dfp_728_90_A" ).css( "right" , "0" ); jQuery( "#dfp_728_90_A" ).css( "left" , "0" ); jQuery( "#dfp_728_90_A" ).css( "z-index" , "999999" ); jQuery( "#dfp_728_90_A" ).css( "top" , "0" ); jQuery( "#dfp_728_90_A" ).css( "transform-origin" , "left top" ); jQuery( "#dfp_728_90_A" ).css( "background-color" , "white" ); jQuery( "#dfp_728_90_A iframe" ).css( "background-color" , "white" ); jQuery( "#dfp_728_90_A" ).css( "padding-bottom" , "1px" ); jQuery( "header#header" ).css( "top" , document.querySelector( "#dfp_728_90_A" ).getBoundingClientRect().bottom ); jQuery( "main" ).css( "padding-top" , document.querySelector( "#dfp_728_90_A" ).getBoundingClientRect().bottom ); fired = true ; setTimeout( function () { jQuery( "#dfp_728_90_A" ).fadeOut( 'slow' , function () { // jQuery( "#dfp_728_90_A" ).show(); jQuery( "#dfp_728_90_A" ).hide(); jQuery( "#dfp_728_90_A" ).css( "position" , "relative" ); jQuery( "#dfp_728_90_A" ).css( "top" , "" ); jQuery( "#dfp_728_90_A" ).css( "left" , "" ); jQuery( "#dfp_728_90_A" ).css( "right" , "" ); jQuery( "#dfp_728_90_A" ).css( "z-index" , "" ); jQuery( "#dfp_728_90_A" ).css( "transform-origin" , "left center " ); jQuery( "#dfp_728_90_A" ).css( "padding-bottom" , "" ); jQuery( "header#header" ).css( "top" , "" ); jQuery( "main" ).css( "padding-top" , "" ); // delete stickBanner; stickBanner = null; }) }, 19000); } // } // }, true ) } function align2device( id, event ) { var adwidth = event.size[0] > 1 ? event.size[0] : '970'; var adheight = event.size[1] > 1 ? event.size[1] : '250'; document.getElementById( id ).style.height = adheight + 'px'; try{ var screenwidth = window.innerWidth; var shrinkpercent = 0; //console.log( event.size ); console.log( adwidth, screenwidth ); //Ελεγχος εαν η διαφήμιση είναι μεγαλύτερη του window size //και υπολογισμός του zoom if (adwidth > screenwidth) { shrinkpercent = Math.round((screenwidth * 100) / adwidth); if (shrinkpercent != 0) { adminheight = Math.round((adheight * shrinkpercent) / 100); } var divBBoard = document.getElementById( id ); if ( divBBoard ){ var leftOffset = ( adwidth - screenwidth ) / -2; divBBoard.style.display = "none"; divBBoard.style.padding = "0px"; divBBoard.style.position = "relative"; divBBoard.style.display = "block"; //divBBoard.style.width = adwidth + "px"; //divBBoard.style.left = leftOffset + "px"; divBBoard.style.webkitTransform = "scale(0." + shrinkpercent + ") "; divBBoard.style.MozTransform = "scale(0." + shrinkpercent + ") " ; divBBoard.style.transform = "scale(0." + shrinkpercent + ") " ; divBBoard.style.transformOrigin = "left top"; divBBoard.style.height = ( adminheight + 10 ) + " !important px"; } } } catch(err){ //console.log(err); } } }); });
Αποχαιρέτησε τους «εχθρούς» του προσώπου σου με αυτές τις αντιγηραντικές στρατηγικές.
Οδηγίες προστασίας για να μη βρεθείς πρόωρα γερασμένη.