How do I add empty line after header in header.php?

2 replies
This is a very simple thing but means a world to me. I have two blogs (those mentioned in the signature). It bothers me that the first ad is right under the header, no space there. I would like to have some space before the ad, maybe just one line.

How can I code one simple, empty line?

So if part of my header.php looks like this:

<div id="navcontainer">
<?php wp_nav_menu( array( 'container' => false, 'theme_location' => 'primary', 'fallback_cb' => 'fadtastic_page_menu' ) ); ?>
</div>
<div id="advertisement">
<?php echo show_ad_camp_1(); ?>
</div>

I would like to program that empty line between those two 'divs' (i.e. before the ad). But how on earth I should do that? Can anybody help me with the code? It must be dead simple but I just cannot figure out how to do it.
#add #empty #header #headerphp #line #php
  • Profile picture of the author Brandon Tanner
    To add some spacing below a div, you would simply increase the 'margin-bottom' style of that div. For example...

    HTML Code:
    <div id="navcontainer" style="margin-bottom: 20px;">
    ^ Then just play around with the pixel value until you get the margin the exact size you want.
    Signature

    {{ DiscussionBoard.errors[8749577].message }}

Trending Topics