Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
#1 2007-09-24 12:38:45
- Gallex
- Member
- Registered: 2006-10-08
- Posts: 1,308
css question: how to leave the space between articles?
if i have little text in article, the next article “drives in” to first.
how to leave the space between articles?
it happens with ff and opera.
Offline
Re: css question: how to leave the space between articles?
First change p.tooted to div.tooted, like this:
<div class="tooted">
<!-- Original article code -->
</div>
Because paragraphs doesn’t allow block-objects inside of them. And now lets add the there one object more, a line breaker <div style="clear:both;"></div>
, like:
<div class="tooted">
<!-- Original article code -->
<div style="clear:both;"></div>
</div>
That overdriving situation was experienced because of the floating-objects, images, won’t obey other elements. Why? Because they float.
Cheers!
Offline
Re: css question: how to leave the space between articles?
imo it’s better to clear floats without using any additional markup, just by the handy css :after pseudo element.
.tooted:after { content: "."; display: block; height: 0; clear: both; visibility: hidden; }
Offline
Re: css question: how to leave the space between articles?
A better way is described here
Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.
Offline
#5 2007-09-24 13:39:35
- Gallex
- Member
- Registered: 2006-10-08
- Posts: 1,308
Re: css question: how to leave the space between articles?
solved. many-many thanks all you guys
Offline