[thelist] IE, CSS and a feeling of futility...

Barry Woolgar barry at burnthebook.co.uk
Tue Sep 25 08:43:15 CDT 2007


Hello

I'm unable to test this at the mo but would it help to have this css class?:

.searchResultsDescription { float: left; }

Without it, the inner floated element (the image) is taken out of the flow
so the main div will actually only be the height of the inline elements (br,
p). What version of IE is this in?
Hope that doesn't cloud the issue!

Barry

-----Original Message-----
From: thelist-bounces at lists.evolt.org
[mailto:thelist-bounces at lists.evolt.org] On Behalf Of Dan Parry
Sent: 25 September 2007 14:35
To: thelist at lists.evolt.org
Subject: [thelist] IE, CSS and a feeling of futility...

Hi all

Having an issue with IE and floats... 'Twas once my understanding that a BR
element with clear: both; declared would cause a container to drop down and
actually contain the floated elements inside... This does work for web
browsers but unfortunately not for IE

I might be missing something (a large portion of my scalp currently) or have
something misunderstood but I don't get this... Here's the CSS and markup if
someone would be kind enough to give it the once over

Markup:
<div class="searchResultsDescription">
   <img src="src" alt="alt" style="height: 50px; width: 50px;" />
   <p>::DESCRIPTION::</p>
   <br />
</div>

CSS:
.searchResultsDescription img {
   float: left;
}

.searchResultsDescription p {
   margin: 0;
   padding: 0;
}

.searchResultsDescription br {
   clear: both;
}

At this point, the description is always shorter than the image which causes
the container in IE to insersect the image mid-point

Thanks in advance for any advice

Dan
--
Dan Parry
Virtua Webtech Ltd


-- 

* * Please support the community that supports you.  * *
http://evolt.org/help_support_evolt/

For unsubscribe and other options, including the Tip Harvester 
and archives of thelist go to: http://lists.evolt.org 
Workers of the Web, evolt ! 


No virus found in this incoming message.
Checked by AVG Free Edition. 
Version: 7.5.488 / Virus Database: 269.13.30/1029 - Release Date: 24/09/2007
19:09
 

No virus found in this outgoing message.
Checked by AVG Free Edition. 
Version: 7.5.488 / Virus Database: 269.13.30/1029 - Release Date: 24/09/2007
19:09
 




More information about the thelist mailing list