Florian Brucker wrote on 07 jun 2004 in
comp.infosystems.
www.authoring.stylesheets:
[color=blue]
> I've got a problem with float & clear. Take this example code:
>
> <div style=" width:100px; height:100px; background-color:#FF0000;
> float:left; margin:10px;"></div>
> <span style="clear:left;">This is some text</span>
>
> In Mozilla 1.6 the span still floats around the image on the left side
> (as if there wasn't a "clear" option). When I use
>
> <h1 style="clear:left;">This is some text</h1>
>
> instead of the span it works as it should (using the h1 without the
> clear-option gives the right result, too, the heading floats around the
> image on the left side).
>
> Is this behaviour correct (according to the specification)? If yes, how
> can I achieve the desired result (the span acting like there was a <br
> clear="all"> infront of it)?
>[/color]
Floating an INLINE element is unreasonable, You should use a floating
block element.
Clearing a float has the same idea: an inline element cannot get clear of
a block.
so try:
<span style="display:block;clear:left;">
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)