Home > Article > Web Front-end > html, xhtml和xml
html, xhtml and xml
1. Definition and characteristics:
1) html: Hyper Text Markup Language Hypertext Markup Language is the earliest language for writing web pages, but its encoding is not standardized and is mainly used to control the display and appearance of data. The syntax is loose and not rigorous;
① Simplicity: The hypertext markup language version upgrade adopts a superset method, making it more flexible and convenient.
② Scalability: The wide application of hypertext markup language has brought about requirements for enhanced functions and added identifiers. Hypertext markup language adopts the method of subclass elements to ensure system expansion.
③ Platform independence: Although personal computers are popular, there are many people using other machines such as Mac. Hypertext Markup Language can be used on a wide range of platforms, which is another reason for the popularity of the World Wide Web (www).
④ Universality: In addition, HTML is the universal language of the Internet, a simple and universal all-in-one markup language. It allows web page producers to create complex pages that combine text and images, and these pages can be viewed by anyone else on the Internet, regardless of the type of computer or browser used.
2) xhtml: eXtensibale Hyper Text Markup Language. The extensible hypertext markup language is actually rigorous and accurate html. It standardizes html and the coding is more rigorous. It is a transitional language from html to xml;
The development history of Html and xhtml:
- HTML 1.0 - Released as an Internet Engineering Task Force (IETF) working draft in June 1993 (not a standard).
- HTML 2.0 - Released as RFC 1866 in November 1995, and in RFC 2854 in 2000 It was declared obsolete after being released in June 2016
- HTML 3.2 - January 14, 1996, W3C Recommendation
- HTML 4.0 - December 18, 1997, W3C Recommendation
- HTML 4.01 (Minor Improvement) - December 24, 1999, W3C Recommended Standard
- ISO/IEC 15445:2000 ("ISO HTML") - Released on May 15, 2000, based on the strict HTML 4.01 syntax, It is a standard of the International Organization for Standardization and the International Electrotechnical Commission
-XHTML 1.0 - released on January 26, 2000, is a W3C recommended standard, and was later revised and re-released on August 1, 2002.
- XHTML 1.1 -- Released on May 31, 2001
3) XML: eXtensibale Markup language is a cross-platform language with more freedom in coding. Provides a way to describe structured data, used to define the structure and data type of the data itself, and is extensible.
W3C is aware of the shortcomings of HTML:
- It cannot solve all problems of interpreting data - such as audio and video files or chemical formulas, music symbols and other types of content;
- Performance issues - the need to download the entire document , can you start searching for files;
- poor scalability, flexibility, and legibility;
In order to solve the above problems, experts use SGML to streamline production, and based on HTML development experience, generate A set of strict rules for use, but a simple language for describing data: XML. XML is a more neutral way that allows the consumer to decide how to digest and present the information provided from the server. The purpose of XML is to provide a mechanism that can accurately describe information to make up for the overly presentation-oriented nature of HTML.
2. The difference between the three:
1) xhtml has good layout and specifications, requiring: a. Elements must have closing tags; b. Elements must be nested correctly;
2) The attribute value of xhtml must be in quotation marks;
3) xhtml does not support minimized attributes: is incorrect, it must be
4) The name attribute in Xhtml is deprecated and will be deleted in future versions
1) Xml specifications are relatively strict, such as: strict case sensitivity
2) Xml tags must be closed, including empty tags
3) Xml must have and only one root tag
4) Xml tags can be customized
We are new here, I lack knowledge, please correct me if I have any shortcomings...
Reference:
[1]W3C Standard
[2] "The Definitive Guide to CSS" (Third Edition)
[3] http://wenku.baidu.com/ Baidu Wenku