Skip to content

Instantly share code, notes, and snippets.

@tingplenting
Created May 22, 2016 07:10
Show Gist options
  • Save tingplenting/1ad017d6e2a671ff81c16e259c9367f3 to your computer and use it in GitHub Desktop.
Save tingplenting/1ad017d6e2a671ff81c16e259c9367f3 to your computer and use it in GitHub Desktop.
<script type="text/javascript">
$(document).ready(function(){
var count = 10;
var countdown = setInterval(function(){
if (count == 0) {
clearInterval(countdown);
$('#googleads-1').load('http//www.example.com/ads/app/adsense.txt');
$('#googleads-2').load('http//www.example.com/ads/app/adsense.txt');
// adsense.txt contain your adsense code
}
count--;
}, 1000);
});
</script>
<div id="googleads-1"></div>
<div id="googleads-2"></div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment