1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

adsense banner inside logo_block

Discussion in 'Styling and Customization Questions' started by xmlxp, Feb 8, 2012.

  1. xmlxp

    xmlxp Active Member

    i put 2 adsense banners inside logo_block like this:

    Code:
    <div id="logoBlock">
     
        <div class="pageWidth">
            <div class="pageContent">
                <xen:include template="ad_header" />
                <xen:hook name="header_logo">
                <div id="logo"><a href="{$logoLink}">
                    <span><xen:comment>This span fixes IE vertical positioning</xen:comment></span>
                  <!-- <img src="@headerLogoPath" alt="{$xenOptions.boardTitle}" /> -->
     
                </a>
     
    <xen:include template="adsense_728x90"/>
    <xen:include template="adsense_728x90"/>
     
    </div>
                </xen:hook>
                <span class="helper"></span>
            </div>
        </div>
    </div>
    
    one of those 2 banners went down outside the logo block, how to fix this?

    here is the adsense_728X90 tamplete:

    Code:
    <div style="text-align: center; margin-top:8px;">
    <!-- GOOGLE ADSENSE CODE STARTS HERE  -->
    <script type="text/javascript"><!--
    google_ad_client = "pub-xxxxxxxxxxxx";
    /* Below Navbar */
    google_ad_slot = "xxxxxxxxxxx";
    google_ad_width = 728;
    google_ad_height = 90;
    //-->
    </script>
    <script type="text/javascript"
    src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
    </script>
    <!--  GOOGLE ADSENSE CODE ENDS HERE -->
     
    </div>
    
     
  2. Brogan

    Brogan XenForo Moderator Staff Member

    Make the logo block height equal to or greater than the height of both adverts.
     
    ShadyX likes this.
  3. xmlxp

    xmlxp Active Member

    I already did that, Height of Header Logo = 250px, but there is somthing pushing the 2 banners a way from each other!
     
  4. Brogan

    Brogan XenForo Moderator Staff Member

    Do you have a link to the page?

    I can check to see what is happening.
     
  5. xmlxp

    xmlxp Active Member

    in the attachments
     

    Attached Files:

  6. Brogan

    Brogan XenForo Moderator Staff Member

    That doesn't help.

    I need to see the source code so I can see what's going on.

    I notice though that you are including the same template twice.
    Try using two different templates.
     
  7. xmlxp

    xmlxp Active Member

    its in my local machine, i tried different tampletes also and it give the same result, as if the logo_block doese not hande more than one banner only
     
  8. Brogan

    Brogan XenForo Moderator Staff Member

    In which case you will need to use Firebug or the Chrome inspection tool to determine what is happening.
     
  9. craigiri

    craigiri Well-Known Member

    You may want to try this stuff on a real url as google adsense can sometimes not serve accurately to anything other than the official URL which you gave them with your account.
    Just an idea.......not sure it would do what you are seeing - but always good to make certain!
     
  10. xmlxp

    xmlxp Active Member

    here is a temporary link online i created just to solve this issue
    http://184.172.223.148/xenforo111/index.php
     
  11. Brogan

    Brogan XenForo Moderator Staff Member

    Add height:90px to each advert div.
     
  12. xmlxp

    xmlxp Active Member

    yes Borgan that did the trick :)
     

Share This Page