This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.
A line-height value of 0 without a length unit generates a parse error and a complaint about an empty string. Adding any length unit value (e.g. "0em") cures the error. Of course, unit values are supposed to be optional. This appears to be a very recently-introduced issue (since 9/25/05 or thereabout).
I can confirm this bug when validating to the CSS3 profile. Line-height of 0 should indeed be valid, as 0 == 0px, 0em, 0en, 0pt, etc.
yes, I came across this bug too ... trying to validate CSS 2.1 source (btw, not the right place to ask but this reminded me ... is there any other way to specify the CSS version 2.1 instead of 2 than using the advanced interface? I mean something within the document itself?)
There is not, see http://lists.w3.org/Archives/Public/www-style/ for details (keywords would be e.g. "@version").
Why has there been no action on this bug in the *100* days since it was reported? Every day that a bug like this is allowed to fester it is embarrassing developers who have gone to the trouble to write valid code and rely on the validator to certify that. Please fix this.
No one provided a patch so far. If someone provides a good patch, I'm happy to commit it and ask Yves to update the online version of the Validator.
Ok, but that's an excuse, not a solution. I'm not blaming you -- in fact I have no idea who in particular is responsible for maintaining the validator. Who needs to have this bug brought to their attention to get some action?
Whoever will write a patch or ensure that someone else will write one...
Do you understand that that means nothing to me as a website developer who relies on this validator to demonstrate to potential clients, etc. that I'm writing valid code? Who is running the show when it comes to this validator? Is there any organizational structure behind it ensuring that things get done?
See http://www.w3.org/QA/Tools/qa-dev/ but note that we are all painfully aware that the CSS Validator is not regularily maintained, in the end it'd be a matter of convincing someone like a W3C Member organization, W3C Management, or some other entity to pay someone to do it.
(In reply to comment #0) > A line-height value of 0 without a length unit generates a parse error and a > complaint about an empty string. Adding any length unit value (e.g. "0em") > cures the error. Of course, unit values are supposed to be optional. This > appears to be a very recently-introduced issue (since 9/25/05 or thereabout). Actually, this seems to happen for any integer number with no unit; see http://jigsaw.w3.org/css- validator/validator?profile=css2&warning=2&uri=http%3A%2F%2Falistapart.com%2F for one such example (line-height: 1;). Apparently another way to step around this bug is to convert to decimal, as in: line-height: 1.0;. Furthermore, unit values aren't optional. United values for line-height have very, very different effects than unitless values; they're as different as apples and oranges.
*** This bug has been marked as a duplicate of 2272 ***