Difference between revisions of "Template:Ads post"

From Enduro.team
Jump to: navigation, search
m
(Tags: Mobile edit, Mobile web edit)
m
 
(48 intermediate revisions by the same user not shown)
Line 2: Line 2:
 
<html>
 
<html>
 
<body>
 
<body>
<!-- admitad.banner: sa4mpjg9ysa031878a9dc51982c87a iport -->
+
<script>
<a target="_blank" rel="nofollow" href="https://ad.admitad.com/g/sa4mpjg9ysa031878a9dc51982c87a/?i=4"><img width="336" height="280" border="0" src="https://ad.admitad.com/b/sa4mpjg9ysa031878a9dc51982c87a/" alt="iport"/></a>
+
if (window.matchMedia) {
<!-- /admitad.banner -->
+
  if(window.matchMedia('(prefers-color-scheme: dark)').matches){
 +
    var d1 = document.getElementById('postadbanner');
 +
    d1.insertAdjacentHTML('beforeend', '<ins class="adsbygoogle" style="display:block; text-align:center;" data-ad-format="fluid" data-ad-client="ca-pub-9226951475373251" data-ad-slot="7972256841"></ins>');
 +
  } else {
 +
    var d1 = document.getElementById('postadbanner');
 +
    d1.insertAdjacentHTML('beforeend', '<ins class="adsbygoogle" style="display:block; text-align:center;" data-ad-format="fluid" data-ad-client="ca-pub-9226951475373251" data-ad-slot="6447563123"></ins>');
 +
  }
 +
} else {
 +
    var d1 = document.getElementById('postadbanner');
 +
    d1.insertAdjacentHTML('beforeend', '<ins class="adsbygoogle" style="display:block; text-align:center;" data-ad-format="fluid" data-ad-client="ca-pub-9226951475373251" data-ad-slot="6447563123"></ins>');
 +
}
 +
</script>
 +
<div class="postadbanner" id="postadbanner" style="width: 90%;">
 +
<script>
 +
    (adsbygoogle = window.adsbygoogle || []).push({});
 +
</script>
 +
</div>
 
</body>
 
</body>
 
</html>
 
</html>
 
</center>
 
</center>
 
__notoc__
 
__notoc__

Latest revision as of 16:03, 22 July 2021