css float block question
Hi current I have somethin开发者_运维知识库g like this:
<div class = "blah">
I
<div class = "car"> am </div>
<div class = "dog"> bob </div>
</div>
where I have
car: float:left, display:block
dog: float:left, display:block
and it comes out in this order:
am bob I
I want it to show:
I am bob
How can I do it by just changing the css?
.car{ display:inline;}
.dog{ display:inline;}
Try this
.blah {float:left, display:block}
精彩评论