Floats and Widths (was Re: Bug)

On 3 Sep 2009, at 15:51, Andreas Prilop wrote:
>> If you test this code you will get a warning "..floated elements
>> need to have a width declared.." even if width is defined.
>
> http://jigsaw.w3.org/css-validator/validator?text=%2Etest%7Bfloat%3Aleft%3Bwidth%3A100px%7D#css

Well, yes. If you use a different test case to the one originally  
provided.

If you use the original code (which has the float and width rules in  
different rule-sets with identical selectors), then it will show the  
warning.

Another, related issue, is that the warning appears when using the CSS  
2.1 profile, despite the requirement being removed: http://www.w3.org/TR/CSS21/changes.html#q58

-- 
David Dorward
http://dorward.me.uk

Received on Thursday, 3 September 2009 15:16:44 UTC