Firefox CSS nowrap problem

user541020 picture user541020 · Feb 23, 2011 · Viewed 9.7k times · Source

I'm trying to create a horizontal (no line breaks) unordered list of images on my website using code as follows:

<ul class="ImageSet">
    <li>
        <img src="blah">
    </li>
    <li>
        <img src="blah">
    </li>
    <li>
        <img src="blah">
    </li>
</ul>

In my CSS, I'm using the following rules:

.ImageSet { white-space: nowrap; }
.ImageSet li { display: inline; float: left; height: 100% }

This is working properly in Chrome, but not in Firefox, for some reason does anyone know why?

EDIT: To clarify, the problem in FF is that the li's still wrap. I'm trying to make them all appear in a single, unbroken horizontal line going off the rightmost edge of the page.

Answer

Prof picture Prof · Feb 24, 2011

Try removing float:left as display:inline should suffice