Meysam  Savameri
Meysam Savameri

Reputation: 556

how can i set space between divs?

this is my html/css code: JsFiddle code

how can i set space between

nav id="section-navi"
section class="section" 
div id="footer-main"

Upvotes: 0

Views: 3274

Answers (2)

Cauliturtle
Cauliturtle

Reputation: 691

you can add "margin-bottom" property to the CSS #section-navi, and "margin-top" to #footer-main. please see below.

#section-navi
{
background: none repeat scroll 0 0 padding-box #FFFFFF;
border: 1px solid #B8B8B8;
border-radius: 0 0 10px 10px;
box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.2);
margin: 10px auto 0px;
min-height: 40px;
padding: 45px 24px 0;
position: relative;
width: 938px;
z-index: 4;
}
#footer-main
{
background: none repeat scroll 0 0 padding-box #21242C;
border-radius: 10px 10px 0 0;
height: 75px;
margin-top: -10px;
padding: 0 24px;
position: relative;
width: 938px;
margin: 10px auto 0px;
}

Upvotes: 1

Lodder
Lodder

Reputation: 19733

Is this what you're after?

HTML:

 <div class="cleaner h20"></div>

CSS:

.cleaner { clear:both; }
.h20 { height: 20px; }

Here is another version of your JSFiddle with the changes:

http://jsfiddle.net/T6md9/1/

Upvotes: 0

Related Questions