Note that there are some explanatory texts on larger screens.

plurals
  1. POcss float problem in a list
    primarykey
    data
    text
    <p>I'm having a problem sorting this out, basically it will be a list with icons and text below. Icon size remains the same but the text doesn't, as shown in the picture <a href="http://i34.tinypic.com/33op84m.jpg" rel="nofollow noreferrer">alt text http://i34.tinypic.com/33op84m.jpg</a> (<a href="http://i34.tinypic.com/33op84m.jpg" rel="nofollow noreferrer">http://i34.tinypic.com/33op84m.jpg</a> ). The problem is when an Li has allot of text the rest float to the right of it. How can I sort this out.</p> <p>Mycodes is below:</p> <pre><code>ul.iconifier { width: 100%; list-style: none; margin: 0 auto; padding: 0; } ul.iconifier li { float: left; margin: 10px; padding: 0; text-align: center; border: 1px solid #ccc; width:8em; height:200px; -moz-border-radius: 3px; /*--CSS3 Rounded Corners--*/ -khtml-border-radius: 3px; /*--CSS3 Rounded Corners--*/ -webkit-border-radius: 3px; /*--CSS3 Rounded Corners--*/ display: block; /*--IE6 Fix--*/ height:101%; } ul.iconifier li a.thumb{ width: 128px; height: 128px; overflow: hidden; display: block; cursor: pointer; } ul.iconifier li a.thumb:hover { } ul.iconifier li p { font: normal 0.75em Verdana, Arial, Helvetica, sans-serif; margin: 0; padding: 10px 5px; background: #f0f0f0; border-top: 1px solid #fff; /*--Subtle bevel effect--*/ text-align:center; width:118px; } ul.iconifier li a {text-decoration: none; color: #777; display: block;} </code></pre> <p>html:</p> <pre><code>&lt;ul class="iconifier"&gt; &lt;li&gt; &lt;a href="#" class="thumb" Title=""&gt;&lt;img src="img/sprite.png" alt="Contacts" /&gt;&lt;/a&gt; &lt;p&gt;&lt;a href="#"&gt;English Depatment&lt;/a&gt;&lt;/p&gt; &lt;/li&gt; &lt;li&gt; &lt;a href="#" class="thumb" title="art"&gt;&lt;img src="img/sprite.png" alt="Art" /&gt;&lt;/a&gt; &lt;p&gt;&lt;a href="#"&gt;Art Deptartment&lt;/a&gt;&lt;/p&gt; &lt;/li&gt; &lt;li&gt; &lt;a href="#" class="thumb" title="Travel and Tourism"&gt;&lt;img src="img/sprite.png" alt="Travel and Tourism" /&gt;&lt;/a&gt; &lt;p&gt;&lt;a href="#"&gt;Mathematics&lt;/a&gt;&lt;/p&gt; &lt;/li&gt; &lt;li&gt; &lt;a href="#" class="thumb" Title=""&gt;&lt;img src="img/sprite.png" alt="Contacts" /&gt;&lt;/a&gt; &lt;p&gt;&lt;a href="#"&gt;Business Studies&lt;/a&gt;&lt;/p&gt; &lt;/li&gt; &lt;li&gt; &lt;a href="#" class="thumb" Title=""&gt;&lt;img src="img/sprite.png" alt="Contacts" /&gt;&lt;/a&gt; &lt;p&gt;&lt;a href="#"&gt;English Depatment with a really long title that will hopefully fall&lt;/a&gt;&lt;/p&gt; &lt;/li&gt; &lt;li&gt; &lt;a href="#" class="thumb" title="art"&gt;&lt;img src="img/sprite.png" alt="Art" /&gt;&lt;/a&gt; &lt;p&gt;&lt;a href="#"&gt;Art Deptartment&lt;/a&gt;&lt;/p&gt; &lt;/li&gt; &lt;li&gt; &lt;a href="#" class="thumb" title="Travel and Tourism"&gt;&lt;img src="img/sprite.png" alt="Travel and Tourism" /&gt;&lt;/a&gt; &lt;p&gt;&lt;a href="#"&gt;Mathematics&lt;/a&gt;&lt;/p&gt; &lt;/li&gt; &lt;li&gt; &lt;a href="#" class="thumb" Title=""&gt;&lt;img src="img/sprite.png" alt="Contacts" /&gt;&lt;/a&gt; &lt;p&gt;&lt;a href="#"&gt;Business Studies&lt;/a&gt;&lt;/p&gt; &lt;/li&gt; &lt;li&gt; &lt;a href="#" class="thumb" Title=""&gt;&lt;img src="img/sprite.png" alt="Contacts" /&gt;&lt;/a&gt; &lt;p&gt;&lt;a href="#"&gt;English Depatment&lt;/a&gt;&lt;/p&gt; &lt;/li&gt; &lt;li&gt; &lt;a href="#" class="thumb" title="art"&gt;&lt;img src="img/sprite.png" alt="Art" /&gt;&lt;/a&gt; &lt;p&gt;&lt;a href="#"&gt;Art Deptartment&lt;/a&gt;&lt;/p&gt; &lt;/li&gt; &lt;/ul&gt; </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload