Google AdSenseのダブルレクタングル

ダブルレクタングル

ダブルレクタングルとはGoogle AdSenseを横に並べて表示する方法。

レクタングルとは、横300ピクセル×高さ250ピクセルの広告です。

コードを取得

Google AdSenseにログイン→[広告の設定]→[広告ユニット]→[新しい広告ユニット]→[テキスト広告とディスプレイ広告]→[名前]へ後でわかるように入力→[表示中]を選び→[カスタムサイズ]→横300ピクセル×高さ250ピクセルと入力→保存してコードを取得→コードを取得→広告コードをコピー

HTML

スポンサーリンク<BR>
<table>
<tr>
<td>
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<!-- コンテンツ下にデフォルト表示(左側) -->
<ins class="adsbygoogle"
style="display:inline-block;width:300px;height:250px"
data-ad-client="ca-pub-●●●●●●●●●●●●●●●●"
data-ad-slot="●●●●●●●●●●"></ins>
<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>
</td>
<td>
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<!-- コンテンツ下にデフォルト表示(右側) -->
<ins class="adsbygoogle"
style="display:inline-block;width:300px;height:250px"
data-ad-client="ca-pub-●●●●●●●●●●●●●●●●"
data-ad-slot="●●●●●●●●●●"></ins>
<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>
</td>
</tr>
</table>

style.css

/* mobile */
@media screen and (max-width: 680px) {
.adsensepc{
display: none !important;
}
}