【问题标题】:How to insert Vertical adsense ad space to my webpage?如何在我的网页中插入垂直 AdSense 广告空间?
【发布时间】:2020-02-26 05:37:16
【问题描述】:

如何在我的网页上为 google adsense 广告创建带有 div 或其他内容的垂直空间,我想在表格的左侧和右侧添加垂直 adsense 广告,请参见下图: https://ibb.co/LNg52NJ

您可以在此处查看实时版本或检查代码: https://translatesubtitles.com/browse_subtitle.php

这是表格代码:

<div class="row">
  <table id="example" data-order='[[ 0, "desc" ]]' class="table table-striped " style="width:100%">
    <thead>
      <tr>
        <th style="display: none">ID</th>
        <th>Name</th>
        <th>Language</th>
        <th>Author</th>
      </tr>
    </thead>

    <tbody>
      <?php
            include("sad.php");
            $query = "SELECT * FROM me order by id DESC";
            $result = mysqli_query($conn, $query);

            if(mysqli_num_rows($result) > 0){

                while($row = mysqli_fetch_array($result)){

                    ?>
        <tr>
          <td style="display: none"><?php echo $row['id']; ?></td>
          <td><a href="ed.php?id=<?php echo $row['id']; ?>"><?php echo $row['name']; ?></a></td>
          <td><?php echo $row['language']; ?></td>
          <td><?php echo $row['author']; ?></td>
        </tr>

      <?php }} ?>

    </tbody>

  </table>
</div>

【问题讨论】:

    标签: html css adsense


    【解决方案1】:

    您可以使用引导列系统并添加如下代码:

    <div class="container">
        <div class="row">
            <div class="col-sm-3"><!-- ad sense --></div>
            <div class="col-sm-6"><!-- your table content --></div>
            <div class="col-sm-3"><!-- ad sense --></div>
        </div>
    </div>
    

    【讨论】:

    • 如果你能分享代码,请问如何增加
      的宽度
    • 我建议看一下引导参考 (link)。 col-md-6 表示该 div 将占据父母宽度的 6/12。
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2020-05-26
    • 2021-01-07
    • 1970-01-01
    • 2020-12-31
    • 2016-02-18
    • 2013-01-06
    相关资源
    最近更新 更多