This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 7180 - XHTML/CSS validations fail when UTF-8 BOM is used
Summary: XHTML/CSS validations fail when UTF-8 BOM is used
Status: RESOLVED FIXED
Alias: None
Product: mobileOK Basic checker
Classification: Unclassified
Component: Java Library (show other bugs)
Version: unspecified
Hardware: PC Linux
: P2 normal
Target Milestone: ---
Assignee: fd
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-07-31 11:51 UTC by fd
Modified: 2009-08-03 15:36 UTC (History)
0 users

See Also:


Attachments

Description fd 2009-07-31 11:51:13 UTC
[
Bug raised by Kevin Ghadyani on the public-mobileok-checker mailing-list:
 http://lists.w3.org/Archives/Public/public-mobileok-checker/2009Jul/0000.html
]

The UTF-8 Byte-Order Mark (BOM) is not defined in mobileOK as a way to precise the content encoding, possibly because some mobile browsers do not handle that pretty well.

That said, it is valid to serve content with a BOM, so this should not trigger any validation failure.

The presence of a BOM currently triggers the following failures:
- Content is not allowed in prolog during XHTML validation
- The style sheet is not syntactically correct during CSS validation

Ex, when run on:
 http://m.kevinghadyani.com/
... the Checker returns a CSS validation error for the mobile style sheet served with a BOM:
 http://m.kevinghadyani.com/mobile.css
Comment 1 fd 2009-08-03 15:36:58 UTC
TextContent now skips the BOM when decoding an UTF-8 string, so as not to confuse the XHTML/CSS validator.