What differences are expected of XHTML5 versus HTM

2019-02-01 09:09发布

问题:

What differences are expected of XHTML5 versus HTML5? I understand that XHTML5 is the XML form of the language and HTML5 is the SGML form of the language, which means obvious minor syntax differences. Will there be any further differences? Will XHTML5 deprecate completely worthless elements that were not deprecated by HTML5? Will XHTML5 be written in schema instead of doctype? Will XHTML5 impose structural validations instead of merely stating what is a child of what? Will XHTML5 offer accessibility advantages that not available in HTML5? Will XHTML5 offer any security enhancements?

Please share any knowledge you have about is claimed to be the future of the web?

回答1:

http://wiki.whatwg.org/wiki/HTML_vs._XHTML is an attempt to document the differences between HTML5 and XHTML5. As far as I know it is the best available resource on this subject to date.



回答2:

What differences are expected of XHTML5 versus HTML5?

The HTML5 "doctype" is not used. The xmlns attribute is required.

I understand that XHTML5 is the XML form of the language and HTML5 is the SGML form of the language

No. HTML5 is not SGML based.

, which means obvious minor syntax differences.

No. Just some forms of syntax become forbidden.

Will XHTML5 deprecate completely worthless elements that were not deprecated by HTML5?

No. They are just different serialisations.

Will XHTML5 be written in schema instead of doctype?

There are, as far as I'm aware, no plans to have an official schema (or DTD for that matter: the doctype is "A thing to trigger standards mode in browsers" and nothing more).

Will XHTML5 impose structural validations instead of merely stating what is a child of what?

No differences from HTML5.

Will XHTML5 offer accessibility advantages that not available in HTML5?

No.

Will XHTML5 offer any security enhancements?

No.