开发者

Floating DIV Containers

Am actually creating a News Container and within it news content with heading, images(if any), summary and eventually a read more link.

The news content is placed in a DIV with a fixed width but i dont want a fixed height however开发者_StackOverflow中文版.

The issue is that i want the containers to float on the left, which works but since the height are not the same am getting a white space between the 3rd and 4th one.

How can i fix this?


you no need to specify height.the height will be automatically adjusted based on the content size.

<div id="news-content"></div>

css

#news-content
{
width:100%;
float:left;
}
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜