How do i put Ad beside the logo in the header?

Discussion in 'HTML & Website Design' started by mirisaamali, Aug 21, 2009.

  1. #1
    Hi,

    Can someone please help me out resolve this problem.

    Here is my site that talks about how to start a website

    When you check the header, you will see that besides the logo on the right hand side, there is a lot of empty space left. I want to have an adsense code or any other ad code of size 468x60 placed there properly. is this possible? if so how do i do it??

    I am using wordpress 2.8.4. Here is the header code from this template:

    sorry for the entire code, i din't know what to put here to help you assist me. Just let me know if there is any code that i need to add and where.
     
    Last edited: Aug 21, 2009
    mirisaamali, Aug 21, 2009 IP
  2. dlb

    dlb Member

    Messages:
    203
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    35
    #2
    Place the following;
    <?php include (TEMPLATEPATH . "/banner728.php"); ?>
    Code (markup):
    Before the closing </div> of the header div.

    Then in the CSS;

    .banner728 { float:right; margin-right:10px; }
    Code (markup):
    The right margin pushes it away from the edge to tidy it up a little, you may want to add top/bottom margin's too to position it better.

    You may need to float your logo too... Thats a case of giving it a class and adding 'float:left;' to #logo in your stylesheet.

    Finally, add the following after the banner include to complete it;
    <br style="clear:both;" />
    Code (markup):
    If the content below your header fails to align correctly look into the BR tag, specifically how to reset its CSS attributes and apply that to your stylesheet. Some browsers add a margin/padding/height/etc to the BR tag by default so applying CSS that resets it will provide a clean 'clear' to your floats which is needed.
     
    Last edited: Aug 21, 2009
    dlb, Aug 21, 2009 IP
  3. mirisaamali

    mirisaamali Well-Known Member

    Messages:
    812
    Likes Received:
    31
    Best Answers:
    0
    Trophy Points:
    118
    #3
    But i cannot place size 728 wide ad in the header, cos the space is only for 468 width. Do i follow the same way for 468 wide ad too?
     
    mirisaamali, Aug 22, 2009 IP
  4. begadang

    begadang Peon

    Messages:
    159
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #4
    Do you want to put ad code such as my site?

    http://godbig.com
    Code (markup):
    (Look at header ad)
     
    begadang, Aug 22, 2009 IP
  5. mirisaamali

    mirisaamali Well-Known Member

    Messages:
    812
    Likes Received:
    31
    Best Answers:
    0
    Trophy Points:
    118
    #5

    Yes exactly! however, i want 468x60 ad size rather than 728x90.
     
    mirisaamali, Aug 22, 2009 IP
  6. mirisaamali

    mirisaamali Well-Known Member

    Messages:
    812
    Likes Received:
    31
    Best Answers:
    0
    Trophy Points:
    118
    #6
    nobody knows how to do it??
     
    mirisaamali, Aug 22, 2009 IP
  7. dlb

    dlb Member

    Messages:
    203
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    35
    #7
    They way I described will work for you. Try it and if it's not what you're looking for just let us know.
     
    dlb, Aug 23, 2009 IP
  8. mirisaamali

    mirisaamali Well-Known Member

    Messages:
    812
    Likes Received:
    31
    Best Answers:
    0
    Trophy Points:
    118
    #8
    I tried it dlb, but it ain't working. :(

    I know its just simple thing, but unfortunately i am not aware of php much hence i am locked down. see what i want is that i need a 468x60 ad prsent in the right side of the header, just like how you have it generally on many other sites.
     
    mirisaamali, Aug 23, 2009 IP