Adsense to the right of content

Discussion in 'HTML & Website Design' started by nickyj83, Jun 16, 2008.

  1. #1
    nickyj83, Jun 16, 2008 IP
  2. noobi

    noobi Peon

    Messages:
    10
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #2
    You need something like this in your .htm file:
    <div id="GoogleAds">
    // Google code
    </div>
    <div id="content">
    // Your content
    </div>

    Then something like this in your .css file:
    #GoogleAds {
    width = 200px;
    float: right;
    }
     
    noobi, Jun 17, 2008 IP
  3. nickyj83

    nickyj83 Well-Known Member

    Messages:
    491
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    128
    #3
    K i will give it go, but where do i put the code in the css file anywhere?
     
    nickyj83, Jun 17, 2008 IP
  4. nicangeli

    nicangeli Peon

    Messages:
    828
    Likes Received:
    23
    Best Answers:
    0
    Trophy Points:
    0
    #4
    Safest bet is to put the code at the bottom of the file.
     
    nicangeli, Jun 17, 2008 IP
  5. NeilsWeb

    NeilsWeb Peon

    Messages:
    17
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #5
    Try something like this:
    Put this in anywhere between the <head></head> tags:
    
    <style type="text/css">
    .ads {
    float:right;
    width: XXX /*Put The Width Of Your Adsense Block Here/*
    }
    </style>
    
    Code (markup):
    And then simply ad the following around your present ad code:
    
    <div class="adsense">
    <--- THIS IS YOUR GOOGLE CODE HERE -->
    </div>
    
    Code (markup):
     
    NeilsWeb, Jun 17, 2008 IP