Created
June 8, 2017 03:47
-
-
Save firewoodyamazaki/f31b1a5e8e8a52c2327273b908eae1ed 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
<!-- アドセンス最初のタグ上 --> | |
<script> | |
var adsenseCode = (function () {/* | |
<p style="text-align: center;"><span style="font-size: 80%;">スポンサーリンク</span><br /> | |
<div class="adbox"> | |
<div class="adsense-left"> | |
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></scrip> | |
<!-- アドセンスコード名 --> | |
<ins class="adsbygoogle" | |
style="display:block" | |
data-ad-client="ca-pub-XXXXXXXXXXXXXXXX" | |
data-ad-slot="XXXXXXXXXX" | |
data-ad-format="rectangle"></ins> | |
<script> | |
(adsbygoogle = window.adsbygoogle || []).push({}); | |
</scrip> | |
</div> | |
<div class="adsense-right"> | |
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></scrip> | |
<!-- アドセンスコード名 --> | |
<ins class="adsbygoogle" | |
style="display:block" | |
data-ad-client="ca-pub-XXXXXXXXXXXXXXXX" | |
data-ad-slot="XXXXXXXXXX" | |
data-ad-format="rectangle"></ins> | |
<script> | |
(adsbygoogle = window.adsbygoogle || []).push({}); | |
</scrip> | |
</div> | |
</div></p> | |
<p> </p> | |
*/}).toString().match(/\/\*([^]*)\*\//)[1].replace(/scrip>/g, 'script>'); | |
addEventListener("DOMContentLoaded", function() { | |
var $target = $('.entry-content h2,h3,h4,h5'); | |
$target.eq(0).before($('.insentense-adsense')); | |
$('.insentense-adsense').html(adsenseCode); | |
}, false); | |
</script> | |
<div class="insentense-adsense"></div> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment