Please send feedback to julian.reschke@gmx.de.
Colors -- Red: Failure, Green: Pass, Yellow: Warning, Grey: Not Supported
Score -- Passes: 2 points, Warning: 1 point, in percent of possible points (this should be updated to count optional features differently)
Test Case | Firefox 79 | Google Chrome 84 | Safari 13.1.2 | |
---|---|---|---|---|
Summary | Score: 89 | Score: 95 | Score: 79 | |
Charset Defaulting | textplainnodefaultutf8 | warn (defaults to ISO-8859 as per RFC 2616) | warn (defaults to ISO-8859 as per RFC 2616) | warn (defaults to ISO-8859 as per RFC 2616) |
textplainnodefaultiso88591 | warn (defaults to ISO-8859 as per RFC 2616) | warn (defaults to ISO-8859 as per RFC 2616) | warn (defaults to ISO-8859 as per RFC 2616) | |
textxmlnodefaultutf8 | pass | pass | pass | |
textxmlnodefaultutf8nodecl | pass | pass | fail (apparently defaults to ISO-8859-1 (see WebKit Bug 215764)) | |
textxmlnodefaultiso88591 | pass | pass | pass | |
textxmlnodefaultiso88591nodecl | fail (attempts to parse with no charset information and fails because ISO-8859-1 is not an autodetected encoding in XML) | pass | pass | |
Charset Parsing | textplainutf8 | pass | pass | pass |
textplainutf8ws | pass (charset parameter ignored) | pass (charset parameter ignored) | warn (either not ignored, or encoding sniffed) | |
textplainutf8qs | pass | pass | pass | |
textplainutf8qsa | pass | pass | warn (either not ignored, or encoding sniffed) | |
textplainutf8qsescaped | pass | pass | fail | |
textplainutf8extparam | pass | pass | pass | |
textplainutf8extparamqs | pass | pass | pass | |
textplainutf8extparamqs1 | pass | pass | pass | |
textplainutf8extparamsq | pass | pass | pass | |
Multiple Field Values | multixmltextoneline | pass (detects text/xml) | pass (detects text/xml) | pass (detects text/plain (!!! - see WebKit Bug 215604)) |
multixmltexttwoline | pass (detects text/xml) | pass (detects text/xml) | pass (detects text/xml) | |
multitextxmloneline | pass (detects text/plain) | pass (detects text/plain) | pass (detects text/xml (!!! - see WebKit Bug 215604)) | |
multitextxmltwoline | pass (detects text/plain) | pass (detects text/plain) | pass (detects text/plain) |
Various tests checking charset defaulting.
Content-Type: text/plain
Payload, encoded in UTF-8:
Umlaute: 漩周 Euro: €
Test Results | |
---|---|
Firefox | warn (defaults to ISO-8859 as per RFC 2616) |
Chrome | warn (defaults to ISO-8859 as per RFC 2616) |
Safari | warn (defaults to ISO-8859 as per RFC 2616) |
text/plain, no charset given, body encoded in UTF-8
Default according to RFC 6657 is US-ASCII
Result for this UA:
Content-Type: text/plain
Payload, encoded in ISO-8859-1:
Umlaute: 漩周
Test Results | |
---|---|
Firefox | warn (defaults to ISO-8859 as per RFC 2616) |
Chrome | warn (defaults to ISO-8859 as per RFC 2616) |
Safari | warn (defaults to ISO-8859 as per RFC 2616) |
text/plain, no charset given, body using ISO-8859-1
Default according to RFC 6657 is US-ASCII
Result for this UA:
Content-Type: text/xml
Payload, encoded in UTF-8:
<?xml version="1.0" encoding="UTF-8"?> <foo>Umlaute: 漩周 Euro: €</foo>
Test Results | |
---|---|
Firefox | pass |
Chrome | pass |
Safari | pass |
text/xml, no charset given, body using UTF-8 (and declaring so)
Result for this UA:
Content-Type: text/xml
Payload, encoded in UTF-8:
<foo>Umlaute: 漩周 Euro: €</foo>
Test Results | |
---|---|
Firefox | pass |
Chrome | pass |
Safari | fail (apparently defaults to ISO-8859-1 (see WebKit Bug 215764)) |
text/xml, no charset given, body using UTF-8 (and not declaring so)
Result for this UA:
Content-Type: text/xml
Payload, encoded in ISO-8859-1:
<?xml version="1.0" encoding="ISO-8859-1"?> <foo>Umlaute: 漩周</foo>
Test Results | |
---|---|
Firefox | pass |
Chrome | pass |
Safari | pass |
text/xml, no charset given, body using ISO-8859-1 (and declaring so)
Result for this UA:
Content-Type: text/xml
Payload, encoded in ISO-8859-1:
<foo>Umlaute: 漩周</foo>
Test Results | |
---|---|
Firefox | fail (attempts to parse with no charset information and fails because ISO-8859-1 is not an autodetected encoding in XML) |
Chrome | pass |
Safari | pass |
text/xml, no charset given, body using ISO-8859-1 (and declaring so)
Result for this UA:
Various tests checking charset parsing.
Content-Type: text/plain; charset=UTF-8
Payload, encoded in UTF-8:
Umlaute: 漩周 Euro: €
Test Results | |
---|---|
Firefox | pass |
Chrome | pass |
Safari | pass |
text/plain, charset UTF-8, body using UTF-8
Result for this UA:
Content-Type: text/plain; charset = UTF-8
Payload, encoded in UTF-8:
Umlaute: 漩周 Euro: €
Test Results | |
---|---|
Firefox | pass (charset parameter ignored) |
Chrome | pass (charset parameter ignored) |
Safari | warn (either not ignored, or encoding sniffed) |
text/plain, charset UTF-8, whitespace around "=", body using UTF-8
Result for this UA:
Content-Type: text/plain; charset="UTF-8"
Payload, encoded in UTF-8:
Umlaute: 漩周 Euro: €
Test Results | |
---|---|
Firefox | pass |
Chrome | pass |
Safari | pass |
text/plain, charset UTF-8 (quoted), body using UTF-8
Result for this UA:
Content-Type: text/plain; charset='UTF-8'
Payload, encoded in UTF-8:
Umlaute: 漩周 Euro: €
Test Results | |
---|---|
Firefox | pass |
Chrome | pass |
Safari | warn (either not ignored, or encoding sniffed) |
text/plain, charset in single quotes, which according to the specs does not match "UTF-8" (it's "'UTF-8'"), body using UTF-8
Result for this UA:
Content-Type: text/plain; charset="UTF-\8"
Payload, encoded in UTF-8:
Umlaute: 漩周 Euro: €
Test Results | |
---|---|
Firefox | pass |
Chrome | pass |
Safari | fail |
text/plain, charset UTF-8 (quoted, using quoted-string escapes), body using UTF-8
Result for this UA:
Content-Type: text/plain; foo=bar; charset="UTF-8"
Payload, encoded in UTF-8:
Umlaute: 漩周 Euro: €
Test Results | |
---|---|
Firefox | pass |
Chrome | pass |
Safari | pass |
text/plain, charset UTF-8 (quoted), with extension parameter before charset parameter, body using UTF-8
Result for this UA:
Content-Type: text/plain; foo="\""; charset="UTF-8"
Payload, encoded in UTF-8:
Umlaute: 漩周 Euro: €
Test Results | |
---|---|
Firefox | pass |
Chrome | pass |
Safari | pass |
text/plain, charset UTF-8 (quoted), with extension parameter using quoted-string syntax before charset parameter, body using UTF-8
Result for this UA:
Content-Type: text/plain; foo="; charset=\"UTF-8\""
Payload, encoded in UTF-8:
Umlaute: 漩周 Euro: €
Test Results | |
---|---|
Firefox | pass |
Chrome | pass |
Safari | pass |
text/plain, extension parameter using quoted-string, with charset param appearing as text content in the extension parameter's value, body using UTF-8
Result for this UA:
Content-Type: text/plain; foo='; charset="UTF-8"
Payload, encoded in UTF-8:
Umlaute: 漩周 Euro: €
Test Results | |
---|---|
Firefox | pass |
Chrome | pass |
Safari | pass |
text/plain, charset UTF-8 (quoted), with extension parameter using a single quote in the token format before charset parameter, body using UTF-8
Result for this UA:
Multiple field values, either comma-separated or in multiple instances. All invalid.
Content-Type: text/plain, text/xml
Payload, encoded in US-ASCII:
<?xml version="1.0"?> <foo>bar</foo>
Test Results | |
---|---|
Firefox | pass (detects text/xml) |
Chrome | pass (detects text/xml) |
Safari | pass (detects text/plain (!!! - see WebKit Bug 215604)) |
multiple field values in one line: plain, then xml, body is XML
Result for this UA:
Content-Type: text/plain Content-Type: text/xml
Payload, encoded in US-ASCII:
<?xml version="1.0"?> <foo>bar</foo>
Test Results | |
---|---|
Firefox | pass (detects text/xml) |
Chrome | pass (detects text/xml) |
Safari | pass (detects text/xml) |
multiple field values in two lines: plain, then xml, body is XML
Result for this UA:
Content-Type: text/xml, text/plain
Payload, encoded in US-ASCII:
<?xml version="1.0"?> <foo>bar</foo>
Test Results | |
---|---|
Firefox | pass (detects text/plain) |
Chrome | pass (detects text/plain) |
Safari | pass (detects text/xml (!!! - see WebKit Bug 215604)) |
multiple field values in one line: xml, then plain, body is XML
Result for this UA:
Content-Type: text/xml Content-Type: text/plain
Payload, encoded in US-ASCII:
<?xml version="1.0"?> <foo>bar</foo>
Test Results | |
---|---|
Firefox | pass (detects text/plain) |
Chrome | pass (detects text/plain) |
Safari | pass (detects text/plain) |
multiple field values in two lines: xml, then plain, body is XML
Result for this UA:
Both this document and the indiviual test "scripts" are generated from one single XML source (httpcontenttype.xml), using an XSLT2 transformation (httpcontenttype.xslt).
To generate the files, an XSLT2 processor such as Saxon 10 is needed. Copy both files into an empty directory, then run:
saxon10 httpcontenttype.xml httpcontenttype.xslt > index.html
Note that this will also generate a set of "asis" files that contain the actual test cases. These can be served using the Apache httpd mod_asis module.