Just nu i M3-nätverket
Jump to content

Float problem.


mindsleep

Recommended Posts

Har 2 kolumner i ett lager. Problemet är att Firefox INTE lägger kolumnerna i lagret när jag floatar kolumnerna.

 

Hur fixa?

 

HTML:

<div id="content">

<div id="leftcol">LEFT</div>

<div id="rightcol">RIGHT</div>

</div>

 

CSS

#content

{

margin:0px auto;

text-align: center;

width: 1000px;

background-color: yellow;

}

 

#leftcol

{

width: 200px;

padding:0px;

margin: 0px;

margin-left: 10px;

/* IE margin float fix */

display:inline;

float: left;

background-color : Blue;

}

 

#rightcol

{

width: 600px;

padding:0px;

margin: 0px;

margin-left: 20px;

float: left;

background-color : Fuchsia;

}

 

//MVH Mindsleep

 

I am who i am, you are who you are, i respect that

 

Link to comment
Share on other sites

lägg till

.clear {height:1px; line-height:1px; clear:both; float:none; visibility:hidden;}

 

<div id="content">
<div id="leftcol">LEFT</div>
<div id="rightcol">RIGHT</div>
[color="#0000ff"]<div class="clear"></div>[/color]
</div>

 

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...