What type of MIME should I use to serve XHTML5 in IE7 and IE8?

I want to use XHTML5, but apparently, two browsers do not accept the application/xhtml+xmlMIME type . I read that they will accept text/xml(or are application/xmlnot sure), but this is a kind of hacking. So I was wondering if I should just send HTML5 to IE7 and IE8?

Please do not talk about the benefits of XHTML and HTML. I know.

+3
source share
3 answers

XHTML 5 is not a standard. XHTML 2 prescribes a new type of doctype, although XHTML 2 is not supported by any modern browsers (since it is mostly incomplete).

HTML5Doctor , "XHTML5" HTML- HTML5, . HTML5 IE7/8.

http://html5doctor.com/html-5-xml-xhtml-5/

, HTML5 () IE < 9 HTML 5 shiv.

http://ejohn.org/blog/html5-shiv/

, MIME XHTML5, application/xhtml+xml application/xml, IE . , , IE 6/7.

+2

:

  • XML.
  • , HTTP, HTML5.
    • <!doctype html> no <?xml ...?> xmlns.
  • Content-Type: text/html; charset=utf-8. ( charset, , PUT ONE IN, UTF-7.)
  • - .

XML - , , , XML-.

, SVG MathML HTML5 HTML5 (<svg> <math> ). ​​

+2

, :

  • ,
    • HTML 5
    • XHTML 1.0
    • HTML 4.01 ** HTML 4.01 Transitional ( , URI)
  • , DTD ( QA)
    • ... spec, HTML 5 ( DTD )
  • , XHTML

Doctype - .

/xhtml + xml , /html , , .

0

Source: https://habr.com/ru/post/1761903/


All Articles