Legend: "feed" treats as feed (displays in feed reader or offers to subscribe) "feed*" treats as feed but complains of unsupported feed format or code errors within the feed "error" displays browser-specific XML error message (see list below) "text" displays as plain text "DL" offers to download file "HTML" renders as HTML (including executing script) "blank" no display, no error message, just a big white window with nothing in it "HTML+feed" renders as HTML (including executing script), then treats as feed "XML" displays as XML with default stylesheet (collapse/expand buttons, etc.) "XMLtext" renders text content only, no script Error messages: Fx.5: (yellow screen of death) "XML Parsing Error..." MSIE8: "The XML page cannot be displayed. Cannot view XML input using XSL style sheet." Op10/Win: "ERROR! XML parsing failed." Saf4: "This page contains the following errors: ... Below is a rendering of the page up to the first error." Tests performed on 2009-09-28 on the most up-to-date point releases of each browser. Test cases available here: http://wearehugh.com/public/2009/09/feeds/ 1) RSS 1.0 example feed from section 4.1 of http://web.resource.org/rss/1.0/spec, with a inserted Notes: this is well-formed XML. Contains both RDF and RSS 1.0 namespace. Content-Type | Fx3.5 | MSIE8 | Op10/Win | Saf4/Win | Saf4/Mac ---------------------------------+-------+-------+----------+----------+--------- application/atom+xml | feed | feed | feed | feed | feed application/rss+xml | feed | feed | feed | feed | feed application/xml | feed | feed | feed | feed | feed text/xml | feed | feed | feed | feed | feed application/rdf+xml | feed | DL | feed | feed | feed application/octet-stream | feed | feed | feed | HTML | HTML text/html | feed | feed | feed | feed | HTML text/plain | text | feed | text | text | text text/plain; charset=utf-8 | text | feed | text | text | text text/plain; charset=windows-1252 | text | feed | text | text | text text/plain; charset=iso-8859-1 | text | feed | text | text | text application/foo+xml | feed | DL | feed | DL | DL application/xml+foo | feed | DL | DL | DL | DL unknown/unknown | DL | DL | DL | DL | DL *blank* | text | feed | HTML+feed| HTML | HTML *missing* | text | feed | feed | text | text 2) fakefoo Notes: this is well-formed XML. Contains both RDF and RSS 1.0 namespace, but RSS 1.0 namespace is only present in an attribute called "fake" (not xmlns). Content-Type | Fx3.5 | MSIE8 | Op10/Win | Saf4/Win | Saf4/Mac ---------------------------------+-------+-------+----------+----------+--------- application/atom+xml | DL | feed* | XML | feed* | feed* application/rss+xml | DL | feed* | XML | feed* | feed* application/xml | XML | feed* | XML | XMLtext | XMLtext text/xml | XML | feed* | XML | XMLtext | XMLtext application/rdf+xml | XML | DL | XML | DL | XMLtext application/octet-stream | DL | feed* | HTML | HTML | HTML text/html | HTML | feed* | HTML | HTML | HTML text/plain | text | feed* | text | text | text text/plain; charset=utf-8 | text | feed* | text | text | text text/plain; charset=windows-1252 | text | feed* | text | text | text text/plain; charset=iso-8859-1 | text | feed* | text | text | text application/foo+xml | DL | DL | XML | DL | DL application/xml+foo | DL | DL | DL | DL | DL unknown/unknown | DL | DL | DL | DL | DL *blank* | text | feed* | HTML | HTML | HTML *missing* | text | feed* | HTML | HTML | HTML 3) foo Notes: this is well-formed XML. Contains RDF namespace but not RSS 1.0 namespace. Content-Type | Fx3.5 | MSIE8 | Op10/Win | Saf4/Win | Saf4/Mac ---------------------------------+-------+-------+----------+----------+--------- application/atom+xml | DL | feed* | XML | feed* | feed* application/rss+xml | DL | feed* | XML | feed* | feed* application/xml | XML | XML | XML | XMLtext | XMLtext text/xml | XML | XML | XML | XMLtext | XMLtext application/rdf+xml | XML | DL | XML | DL | XMLtext application/octet-stream | DL | HTML | HTML | HTML | HTML text/html | HTML | HTML | HTML | HTML | HTML text/plain | text | HTML | text | text | text text/plain; charset=utf-8 | text | HTML | text | text | text text/plain; charset=windows-1252 | text | HTML | text | text | text text/plain; charset=iso-8859-1 | text | HTML | text | text | text application/foo+xml | DL | DL | XML | DL | DL application/xml+foo | DL | DL | DL | DL | DL unknown/unknown | DL | DL | DL | DL | DL *blank* | text | HTML | HTML | HTML | HTML *missing* | text | HTML | HTML | HTML | HTML 4) double fakefoo Notes: this is not well-formed XML. Contains both RDF and RSS 1.0 namespace strings, but both are only in fake (non-xmlns) attributes. Content-Type | Fx3.5 | MSIE8 | Op10/Win | Saf4/Win | Saf4/Mac ---------------------------------+-------+-------+----------+----------+--------- application/atom+xml | DL | feed* | error | feed* | feed* application/rss+xml | DL | feed* | error | feed* | feed* application/xml | error | feed* | error | error | error text/xml | error | feed* | error | error | error application/rdf+xml | error | DL | error | DL | error application/octet-stream | DL | feed* | HTML | HTML | HTML text/html | HTML | feed* | HTML | HTML | HTML text/plain | text | feed* | text | text | text text/plain; charset=utf-8 | text | feed* | text | text | text text/plain; charset=windows-1252 | text | feed* | text | text | text text/plain; charset=iso-8859-1 | text | feed* | text | text | text application/foo+xml | DL | DL | error | DL | DL application/xml+foo | DL | DL | DL | DL | DL unknown/unknown | DL | DL | DL | DL | DL *blank* | text | feed* | HTML | HTML | HTML *missing* | text | feed* | HTML | HTML | HTML 5) not even closefoo Notes: this is not well-formed XML. Contains both RDF and RSS 1.0 namespace strings, but both are just floating in the start tag where an attribute name should be. Content-Type | Fx3.5 | MSIE8 | Op10/Win | Saf4/Win | Saf4/Mac ---------------------------------+-------+-------+----------+----------+--------- application/atom+xml | DL | feed* | error | feed* | feed* application/rss+xml | DL | feed* | error | feed* | feed* application/xml | error | feed* | error | error | error text/xml | error | feed* | error | error | error application/rdf+xml | error | DL | error | DL | error application/octet-stream | DL | feed* | HTML | HTML | HTML text/html | HTML | feed* | HTML | HTML | HTML text/plain | text | feed* | text | text | text text/plain; charset=utf-8 | text | feed* | text | text | text text/plain; charset=windows-1252 | text | feed* | text | text | text text/plain; charset=iso-8859-1 | text | feed* | text | text | text application/foo+xml | DL | DL | error | DL | DL application/xml+foo | DL | DL | DL | DL | DL unknown/unknown | DL | DL | DL | DL | DL *blank* | text | feed* | HTML | HTML | HTML *missing* | text | feed* | HTML | HTML | HTML 6) http://www.w3.org/1999/02/22-rdf-syntax-ns# http://purl.org/rss/1.0/outside start tagfoo Notes: this is not well-formed XML. Contains both RDF and RSS 1.0 namespace strings, but neither occurs within a start tag. Content-Type | Fx3.5 | MSIE8 | Op10/Win | Saf4/Win | Saf4/Mac ---------------------------------+-------+-------+----------+----------+--------- application/atom+xml | DL | feed* | error | feed* | feed* application/rss+xml | DL | feed* | error | feed* | feed* application/xml | error | feed* | error | error | error text/xml | error | feed* | error | error | error application/rdf+xml | error | DL | error | DL | error application/octet-stream | DL | feed* | HTML | HTML | HTML text/html | HTML | feed* | HTML | HTML | HTML text/plain | text | feed* | text | text | text text/plain; charset=utf-8 | text | feed* | text | text | text text/plain; charset=windows-1252 | text | feed* | text | text | text text/plain; charset=iso-8859-1 | text | feed* | text | text | text application/foo+xml | DL | DL | error | DL | DL application/xml+foo | DL | DL | DL | DL | DL unknown/unknown | DL | DL | DL | DL | DL *blank* | text | feed* | HTML | HTML | HTML *missing* | text | feed* | HTML | HTML | HTML 7) foo Notes: this is not well-formed XML. Contains neither RDF nor RSS 1.0 namespace. Content-Type | Fx3.5 | MSIE8 | Op10/Win | Saf4/Win | Saf4/Mac ---------------------------------+-------+-------+----------+----------+--------- application/atom+xml | DL | feed* | error | feed* | feed* application/rss+xml | DL | feed* | error | feed* | feed* application/xml | error | error | error | error | error text/xml | error | error | error | error | error application/rdf+xml | error | DL | error | DL | error application/octet-stream | DL | text | text | DL | DL text/html | HTML | blank | HTML | HTML | HTML text/plain | text | HTML | text | text | text text/plain; charset=utf-8 | text | HTML | text | text | text text/plain; charset=windows-1252 | text | HTML | text | text | text text/plain; charset=iso-8859-1 | text | HTML | text | text | text application/foo+xml | DL | DL | error | DL | DL application/xml+foo | DL | DL | DL | DL | DL unknown/unknown | DL | DL | DL | DL | DL *blank* | text | HTML | HTML | HTML | HTML *missing* | text | HTML | HTML | HTML | HTML 8) fake Notes: this is not well-formed XML. Contains both RDF and RSS 1.0 namespaces, in properly-named xmlns attributes. Content-Type | Fx3.5 | MSIE8 | Op10/Win | Saf4/Win | Saf4/Mac ---------------------------------+-------+-------+----------+----------+--------- application/atom+xml | DL | feed* | error | feed* | application/rss+xml | DL | feed* | error | feed* | application/xml | error | feed* | error | XMLtext | text/xml | error | feed* | error | XMLtext | application/rdf+xml | error | DL | error | DL | application/octet-stream | DL | feed* | HTML | HTML | text/html | HTML | feed* | HTML | HTML | text/plain | text | feed* | text | text | text/plain; charset=utf-8 | text | feed* | text | text | text/plain; charset=windows-1252 | text | feed* | text | text | text/plain; charset=iso-8859-1 | text | feed* | text | text | application/foo+xml | DL | DL | error | DL | application/xml+foo | DL | DL | DL | DL | unknown/unknown | DL | DL | DL | DL | *blank* | text | feed* | HTML | HTML | *missing* | text | feed* | HTML | HTML | 9) Notes: this is just a series of 3 comments, followed by a bit of JavaScript. Content-Type | Fx3.5 | MSIE8 | Op10/Win | Saf4/Win | Saf4/Mac ---------------------------------+-------+-------+----------+----------+--------- application/atom+xml | DL | feed* | XML | feed* | application/rss+xml | DL | feed* | XML | feed* | application/xml | XML | feed* | XML | XMLtext | text/xml | XML | feed* | XML | XMLtext | application/rdf+xml | XML | feed* | XML | XMLtext | application/octet-stream | DL | feed* | HTML | HTML | text/html | HTML | feed* | HTML | HTML | text/plain | text | feed* | text | text | text/plain; charset=utf-8 | text | feed* | text | text | text/plain; charset=windows-1252 | text | feed* | text | text | text/plain; charset=iso-8859-1 | text | feed* | text | text | application/foo+xml | DL | DL | XML | DL | application/xml+foo | DL | DL | DL | DL | unknown/unknown | DL | DL | DL | DL | *blank* | HTML | feed* | HTML | HTML | *missing* | HTML | feed* | HTML | HTML | COMMENTS: - Firefox doesn't have a mode for "I treated this as a feed but it's broken, so I'm showing you an error message." If Firefox sniffs a resource as a feed and then fails to parse it as a feed, Firefox automatically reparses the resource with feed sniffing disabled. - Each browser treats "application/atom+xml" and "application/rss+xml" identically in all situations. - Each browser treats "application/xml" and "text/xml" identically in all situations. - Each browser treats "text/plain", "text/plain; charset=utf-8", "text/plain; charset=windows-1252", and "text/plain; charset=iso-8859-1" identically in all sutations. Specifying a charset parameter does not make any browser more or less willing to sniff. - MSIE always sniffs "text/plain" (with or without a charset parameter). No other browser does this. - Firefox and Opera are the only browsers that treat a valid RSS 1.0 feed served as "application/foo+xml" as a feed. - Firefox is the only browser that treats a valid RSS 1.0 feed served as "application/xml+foo" as a feed. - MSIE is the only browser that does NOT treat a valid RSS 1.0 feed served as "application/rdf+xml" as a feed. - Only MSIE and Opera treat a valid RSS 1.0 feed served without a Content-Type as a feed. This, despite the fact that RFC 2616 *explicitly states* that user agents may perform content sniffing if the response is missing a Content-Type header. - Safari/Win and Safari/Mac differ on several tests. - MSIE treats the following Content-Types as feeds, unilaterally (no sniffing): - "application/atom+xml" - "application/rss+xml" - MSIE triggers feed sniffing with the following Content-Types: - "application/xml" - "text/xml" - "application/octet-stream" - "text/html" - "text/plain" (with or without a charset parameter) - when the Content-Type header is blank - when the Content-Type header is missing - Once MSIE has decided to sniff, it looks for the strings "