HighDots Forums  

Firefox doesn't handle float:right in UL correctly

Cascading Style Sheets Layout/presentation on the WWW (comp.infosystems.www.authoring.stylesheets)


Discuss Firefox doesn't handle float:right in UL correctly in the Cascading Style Sheets forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Daniel Jung
 
Posts: n/a

Default Firefox doesn't handle float:right in UL correctly - 04-07-2008 , 05:43 PM






Hi

I got this question from a user. It stumped me, and I'm hoping for some
enlightenment from the community now. It is about centering images in a
<ul>, and right margin in subsequent <li>s after a float. Firefox
doesn't render the site as expected, while both Opera and IE does. CSS
and XHTML do validate. Please tell me if you need/prefer a minimal case.

Her case and comment:

Firefox/Mozilla will not wrap text after an image that is floated
right if the text is part of an unordered list instead of a regular
paragraph. According to all the rules, the text is suppose to wrap
under the image, and does so perfectly in IE. Here is the page:
<http://www.vroma.org/help/builder.html>

Look in the section called Editing Rooms, under Description. That
image <http://www.vroma.org/help/description.jpg> is supposed to be
centered, but it is is aligned left. Even worse is the section called
Bots. The text of list item Strings should wrap beneath the image,
but it does not. Instead there is a long blank space on the right
where nothing wraps or clears until Keywords. I have tried adding
the class .cleared {clear: both;} to various list items, to no avail.
If you look at the same page in IE it renders perfectly. I have
looked and looked and can't find any reason for this. All the CSS
books say it should work.


Thanks for any comments.

- Daniel

Reply With Quote
  #2  
Old   
dorayme
 
Posts: n/a

Default Re: Firefox doesn't handle float:right in UL correctly - 04-07-2008 , 06:23 PM






In article <47FAA3A9.5070503 (AT) uib (DOT) no>, Daniel Jung <jung (AT) uib (DOT) no> wrote:

Quote:
Hi

I got this question from a user. It stumped me, and I'm hoping for some
enlightenment from the community now. It is about centering images in a
ul>, and right margin in subsequent <li>s after a float. Firefox
doesn't render the site as expected, while both Opera and IE does. CSS
and XHTML do validate. Please tell me if you need/prefer a minimal case.

Her case and comment:

Firefox/Mozilla will not wrap text after an image that is floated
right if the text is part of an unordered list instead of a regular
paragraph. According to all the rules, the text is suppose to wrap
under the image, and does so perfectly in IE. Here is the page:
http://www.vroma.org/help/builder.html

Look in the section called Editing Rooms, under Description. That
image <http://www.vroma.org/help/description.jpg> is supposed to be
centered, but it is is aligned left. Even worse is the section called
Bots. The text of list item Strings should wrap beneath the image,
but it does not. Instead there is a long blank space on the right
where nothing wraps or clears until Keywords. I have tried adding
the class .cleared {clear: both;} to various list items, to no avail.
If you look at the same page in IE it renders perfectly. I have
looked and looked and can't find any reason for this. All the CSS
books say it should work.


Thanks for any comments.

- Daniel
Just a quick response for now: have you tried adding to your:

ul li {
padding: 2px 0;
}

thus:

ul li {
padding: 2px 0;
width: 100%;
}

This jogs FF into flowing as you might want.

--
dorayme


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.