Viewing 19 posts - 1 through 19 (of 19 total)
  • Author
    Posts
  • #4153

    How do i add a banner to the header?

    #45206

    Hey,

    in header.php add your banner code after:

    <h2 class="logo ie6fix <?php echo $logoclass; ?>"><a>/"><?php echo $logo; ?></a></h2>

    Ifyou like you can position it by wrapping it in a div – i.e.like:

    <div class="banner">
    banner code
    </div>

    At least add following css to style.css:

    .banner {
    position: absolute;
    right: 0px;
    top: 90px;
    }

    Obviously you can adjust the css class and the position as you like.

    #45207

    I’m sorry, I meant an avert banner in the upper right corner of the header file. Right below the twitter and feeder icons, here’s my sight:

    http://www.innohealthed.org.

    I tried this code:   <div align="right" style="position: absolute; top: 50px; right: 0; z-index:10;"><a href="http://innohealthed.org/healthpreneurs.html"><img src="addesign.gif" /></a></div>

    But it doesn’t work properly. I would appreciate your help.

    #45208

    Try:

    <div style="position: absolute; top: 50px; right: 0; z-index:10;"><a href="http://innohealthed.org/healthpreneurs.html"><img src="http://my-website.com/addesign.gif" /></a></div>

    Instead of http://my-website.com/addesign.gif insert the ABSOLUTE path to your image (so use http://innohealthed.org/image-path )

    #45209

    Tried it, and it doesn’t work. I must be doing something wrong. Can’t figure it out???

    #45210

    I couldn’t find the banner code on your website. Please leave it – maybe it’s just a smal php problem or the image url isn’t right. Wuithout code I can’t investigate what’s going wrong….

    #45212

    Want to put your new banner ad on your own website or homepage?

    It’s easy, just follow these steps:

    1. Download your ad to your PC/Mac as described above (or receive it via email if you prefer);

    2. Upload your ad from your PC/Mac to your webpage (if you need help uploading, please contact your webpage host’s support materials);

    3. Add the following HTML code to your webpage so that it loads and displays your new banner ad:

    <img src="addesign.gif" /> (this code will simply display your ad - clicking on it will do nothing)

    (if you uploaded your ad using a different file name, change “addesign.gif” to the file name you used)

    OR use the following HTML code to display your banner and cause people who click on it

    to be taken to a specific page on your website:

    <a href="http://www.innohealthed.org/anypage.html"><img src="addesign.gif" /></a>

    (if you uploaded your ad using a different file name, change “addesign.gif” to the file name you used).

    That’s all there is to it – your ad should now appear on your webpage for all the world to see and enjoy!

    #45214

    Glad that you found a solution.

    #45215

    No, i didn’t find a solution yet. I submitted to you the directions for my avert banner. I still can’t figure how to put in on my website.

    #45216

    I think the problem is the link to your image. Please make the modification in header.php (like I instructed above) and leave it. I’ll investigate the site with firebug afterwards.

    #45217

    OK, I made the modifications in my header.php file.

    #45218

    I was right. The url: http://innohealthed.org/addesign.gif is wrong and doesn’t point to an image. I.e. if you try to insert your logo like:

    <div style="position: absolute; top: 50px; right: 0; z-index:10;">
    <a href="http://innohealthed.org/healthpreneurs.html">
    <img src="http://www.innohealthed.org/wp-content/uploads/2011/04/ihe-logo.png">
    </a>
    </div>

    it works because the image exists. However http://innohealthed.org/addesign.gif doesn’t exist. You need to upload the image to the main server directory or (better solution) you put it in wp-content/uploads folder – the path would be http://www.innohealthed.org/wp-content/uploads/addesign.gif then.

    #45219

    Perfect!! Thanks for your patients and time you given to help me. I appreciate it immensely.

    #45220

    Oh, can I link this new avert banner to one of my post?

    #45221

    Yes – just replace http://innohealthed.org/healthpreneurs.html with the permalink of the post you want to link to.

    #45222

    Thanks, your the Man!

    #45223

    I meant you’re the Man!

    #45224

    Glad that I could help you :)

    #45225

    Hi, I’ve followed the instructions above but there’s still a problem. The logo to the right of the main logo works fine on the home page but on all other pages it’s positioned on the left edge (should be 300 px left). Help greatly appriciated.

    http://bioparadis.is/

Viewing 19 posts - 1 through 19 (of 19 total)

The topic ‘How to add a banner to the header’ is closed to new replies.