• bvanraaij

    (@bvanraaij)


    I’m trying to place a picture, the logo of my website, in front of my header, the title of the website.

    However, this ruïns the format. My H1 stays on the bottom of the picture, not centered, and H2 becomes invisible.

    Can anybody help me with this challenge? Maybe it’s possible to make a table, with 1 cell on the left with te pictures, and 2 rows on the right with H1 and H2.

    I hope You can help me.

    ...
    
    <div id="wrap">
    <div id="top">
    <div id="header">
    <h1 class="blogtitle"><a href="<?php echo get_option('home'); ?>/"><?php bloginfo('name'); ?></a></h1>
    <p class="desc"><?php bloginfo('description'); ?></p>
    <link rel="shortcut icon" href="BarChart.ico">
    </div>
    <div id="nav">
    <ul class="nav">
    <li><a href="<?php bloginfo('url'); ?>">Home</a></li>
    <?php wp_list_pages('title_li='); ?>
    </ul>
    </div></div>
    <div id="main">
Viewing 2 replies - 1 through 2 (of 2 total)
  • csleh

    (@csleh)

    difficult to answer, it depends on your theme, the image size, the css settings for wrap, top, header, h1 and img. The code above doesn’t even have an h2 — there is a <p>. Does invisible mean the image is on top of the text? below it?

    You might try adding a class to your image like <img class=”floatimage” …/>
    then in the stylesheet specify the class
    ‘.floatimage {float:left; margin-right:12px;}’
    and perhaps then play with padding on the h1 like so
    ‘#header h1 {padding-top:6px;}’
    or even line-height.

    Thread Starter bvanraaij

    (@bvanraaij)

    Csleh, thanks for your reaction.

    There is no H2, that’s right. The text is under the bar of the header, and is thereby invisible.

    I’ll give your suggestion a try, thank you!

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Insert image in header ruïns the format’ is closed to new replies.