Created
January 31, 2017 11:21
-
-
Save liamg/cb55c042fc18d989abd2946837f0a7e5 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Basic spoofer for GADX that always passes back. | |
*/ | |
window.addEventListener("load", function load(event){ | |
window.removeEventListener("load", load, false); //remove listener, no longer needed | |
if(typeof google_alternate_ad_url !== 'undefined') | |
{ | |
var iframe = document.createElement('iframe'); | |
try{ iframe.style = 'width:0px;height:0px;border:none;'; }catch(e){} | |
document.body.appendChild(iframe); | |
iframe.src = google_alternate_ad_url; | |
top.google_cpm = typeof google_cpm !== 'undefined' ? google_cpm : null; | |
} | |
},false); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment