Jump to content

HTML5

From Wikipedia, the free encyclopedia

This is an old revision of this page, as edited by 218.186.17.248 (talk) at 18:13, 31 October 2011 (Corrected grammatical error (previously the sentence said that the *WWW* was a "core technology of the Internet proposed by Opera Software").). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.

HTML5
(HyperText Markup Language)
Filename extension
.html, .htm
Internet media type
text/html
Type codeTEXT
Uniform Type Identifier (UTI)public.html
Developed byWorld Wide Web Consortium and WHATWG
Type of formatMarkup language
Extended fromSGML
Extended toXHTML5
Free format?Yes
Websitewhatwg.org/html
www.w3.org/TR/html5
XHTML5
Filename extension
.xhtml, .xht, .xml, .html, .htm
Internet media type
application/xml, application/xhtml+xml
Developed byWorld Wide Web Consortium and WHATWG
Type of formatMarkup language
Extended fromXML, HTML5
Free format?Yes
Websitewww.whatwg.org/specs/web-apps/current-work/multipage/the-xhtml-syntax.html

HTML5 is a language for structuring and presenting content for the World Wide Web, and is a core technology of the Internet originally proposed by Opera Software.[1] It is the fifth revision of the HTML standard (created in 1990 and standardized as HTML4 as of 1997[2]) and as of October 2011 is still under development. Its core aims have been to improve the language with support for the latest multimedia while keeping it easily readable by humans and consistently understood by computers and devices (web browsers, parsers, etc.). HTML5 is intended to subsume not only HTML 4, but XHTML 1 and DOM2HTML (particularly JavaScript) as well.[2]

Following its immediate predecessors HTML 4.01 and XHTML 1.1, HTML5 is a response to the observation that the HTML and XHTML in common use on the World Wide Web is a mixture of features introduced by various specifications, along with those introduced by software products such as web browsers, those established by common practice, and the many syntax errors in existing web documents. It is also an attempt to define a single markup language that can be written in either HTML or XHTML syntax. It includes detailed processing models to encourage more interoperable implementations; it extends, improves and rationalises the markup available for documents, and introduces markup and application programming interfaces (API)s for complex web applications.[3] For the same reasons, HTML5 is also a potential candidate for cross-platform mobile applications. Many features of HTML5 have been built with the consideration of being able to run on low-powered devices such as smartphones and tablets.

In particular, HTML5 adds many new syntactical features. These include the <video>, <audio>, <header> and <canvas> elements, as well as the integration of SVG content that replaces the uses of generic <object> tags. These features are designed to make it easy to include and handle multimedia and graphical content on the web without having to resort to proprietary plugins and APIs. Other new elements, such as <section>, <article>, <header> and <nav>, are designed to enrich the semantic content of documents. New attributes have been introduced for the same purpose, while some elements and attributes have been removed. Some elements, such as <a>, <cite> and <menu> have been changed, redefined or standardized. The APIs and document object model (DOM) are no longer afterthoughts, but are fundamental parts of the HTML5 specification.[3] HTML5 also defines in some detail the required processing for invalid documents so that syntax errors will be treated uniformly by all conforming browsers and other user agents.[4]

History

The Web Hypertext Application Technology Working Group (WHATWG) began work on the new standard in 2004, when the World Wide Web Consortium (W3C) was focusing future developments on XHTML 2.0, and HTML 4.01 had not been updated since 2000.[5] In 2009, the W3C allowed the XHTML 2.0 Working Group's charter to expire and decided not to renew it. W3C and WHATWG are currently working together on the development of HTML5.[6]

Even though HTML5 has been well known among web developers for years, it became the topic of mainstream media in April 2010[7][8][9][10] after Apple Inc's then-CEO Steve Jobs issued a public letter titled "Thoughts on Flash" where he concludes that Adobe "Flash is no longer necessary to watch video or consume any kind of web content" and that "new open standards created in the mobile era, such as HTML5, will win".[11] This sparked a debate in web development circles where some suggested that while HTML5 provides enhanced functionality, developers must consider the varying browser support of the different parts of the standard as well as other functionality differences between HTML5 and Flash.[12]

W3C standardization process

WHATWG started work on the specification in June 2004 under the name Web Applications 1.0.[13] As of January 2011, the specification is in the Draft Standard state at the WHATWG, and in Working Draft state at the W3C. Ian Hickson of Google is the editor of HTML5.[14]

The HTML5 specification was adopted as the starting point of the work of the new HTML working group of the World Wide Web Consortium (W3C) in 2007. This working group published the First Public Working Draft of the specification on 22 January 2008.[15] The specification is an ongoing work, and is expected to remain so for many years, although parts of HTML5 are going to be finished and implemented in browsers before the whole specification reaches final Recommendation status.[16]

According to the W3C timetable, it was estimated that HTML5 would reach W3C Recommendation by late 2010. However, the First Public Working Draft estimate was missed by eight months, and Last Call and Candidate Recommendation were expected to be reached in 2008,[17] but as of January 2011 HTML5 is still at Working Draft stage in the W3C.[18] HTML5 has been at Last Call in the WHATWG since October 2009.[19][20]

Ian Hickson, editor of the HTML5 specification, expects the specification to reach the Candidate Recommendation stage during 2012.[21] The criterion for the specification becoming a W3C Recommendation is “two 100% complete and fully interoperable implementations”.[21] In an interview with TechRepublic, Hickson guessed that this would occur in the year 2022 or later.[22] However, many parts of the specification are stable and may be implemented in products:

Some sections are already relatively stable and there are implementations that are already quite close to completion, and those features can be used today (e.g. <canvas>).

— WHAT Working Group, When will HTML5 be finished?[21], FAQ

In December 2009, WHATWG switched to an unversioned development model for the HTML5 specification.[23] W3C will still continue with publishing a snapshot of the HTML5 specification.[24]

On 14 February 2011, the W3C extended the charter of its HTML Working Group with clear milestones for HTML5. The Working Group is expected to advance HTML5 to "Last Call", an invitation to communities inside and outside W3C to confirm the technical soundness of the specification, in May 2011. The group will then shift focus to gathering implementation experience. W3C is also developing a comprehensive test suite to achieve broad interoperability for the full specification by 2014, which is now the target date for Recommendation.[25]

Even as innovation continues, advancing HTML5 to Recommendation provides the entire Web ecosystem with a stable, tested, interoperable standard. The decision to schedule the HTML5 Last Call for May 2011 was an important step in setting industry expectations. Today we take the next step, announcing 2014 as the target for Recommendation.

— Jeff Jaffe, Chief Executive Officer, World Wide Web Consortium[25]

Markup

HTML5 introduces a number of new elements and attributes that reflect typical usage on modern websites. Some of them are semantic replacements for common uses of generic block (<div>) and inline (<span>) elements, for example <nav> (website navigation block), <footer> (usually referring to bottom of web page or to last lines of HTML code), or <audio> and <video> instead of <object>.[26][27][28] Some deprecated elements from HTML 4.01 have been dropped, including purely presentational elements such as <font> and <center>, whose effects are achieved using Cascading Style Sheets. There is also a renewed emphasis on the importance of DOM scripting (e.g., JavaScript) in Web behavior.

The HTML5 syntax is no longer based on SGML despite the similarity of its markup. It has, however, been designed to be backward compatible with common parsing of older versions of HTML. It comes with a new introductory line that looks like an SGML document type declaration, <!DOCTYPE html>, which triggers the standards-compliant rendering mode.[29] As of 5 January 2009, HTML5 also includes Web Forms 2.0, a previously separate WHATWG specification.

New APIs

In addition to specifying markup, HTML5 specifies scripting application programming interfaces (APIs).[30] Existing document object model (DOM) interfaces are extended and de facto features documented. There are also new APIs, such as:

Template:Multicol

| class="col-break " |

|}

Not all of the above technologies are included in the W3C HTML5 specification, though they are in the WHATWG HTML specification.[34] Some related technologies, which are not part of either the W3C HTML5 or the WHATWG HTML specification, are as follows. The W3C publishes specifications for these separately.

Template:Multicol

| class="col-break " |

|}

A common misconception is that HTML5 can provide animation within web pages, which is untrue. Either JavaScript or CSS3 is necessary for animating HTML elements. Animation is also possible using JavaScript and HTML 4[40][failed verification], and within SVG elements through SMIL, although browser support of the latter remains uneven as of 2011.

XHTML5

XHTML5 is the XML serialization of HTML5. XML documents must be served with an XML Internet media type such as application/xhtml+xml or application/xml.[41] XHTML5 requires XML's strict, well-formed syntax. The choice between HTML5 and XHTML5 boils down to the choice of a MIME/content type: the media type you choose determines what type of document should be used.[42] In XHTML5 the HTML5 doctype html is optional and may simply be omitted.[43] HTML that has been written to conform to both the HTML and XHTML specifications—and which will therefore produce the same DOM tree whether parsed as HTML or XML—is termed "polyglot markup".[44]

Error handling

An HTML5 (text/html) browser will be flexible in handling incorrect syntax. HTML5 is designed so that old browsers can safely ignore new HTML5 constructs. In contrast to HTML 4.01, the HTML5 specification gives detailed rules for lexing and parsing, with the intent that different compliant browsers will produce the same result in the case of incorrect syntax.[45] Although HTML5 now defines a consistent behavior for "tag soup" documents, those documents are not regarded as conforming to the HTML5 standard.[45]

Popularity

According to a report released on 30 September 2011, 34% of the world's top 100 Web sites were using HTML5 - the adaptation led by search engines and social networks.[46]

On 20 October 2011, Facebook announced the launch of the HTML Resource Center, giving developers tools to build, test and deploy Facebook applications.[47]


Differences from HTML 4.01 and XHTML 1.x

The following is a cursory list of differences and some specific examples. Template:Multicol

  • New parsing rules: oriented towards flexible parsing and compatibility; not based on SGML
  • Ability to use inline SVG and MathML in text/html
  • New elements: article, aside, audio, bdo, canvas, command, datalist, details, embed, figcaption, figure, footer, header, hgroup, keygen, mark, meter, nav, output, progress, rp, rt, ruby, section, source, summary, time, video, wbr

| class="col-break " |

  • New types of form controls: dates and times, email, url, search, number, range, tel, color[48]
  • New attributes: charset (on meta), async (on script)
  • Global attributes (that can be applied for every element): id, tabindex, hidden, data-* (custom data attributes)
  • Deprecated elements will be dropped altogether: acronym, applet, basefont, big, center, dir, font, frame, frameset, isindex, noframes, strike, tt

|}

dev.w3.org provides the latest Editors Draft (last dated 4 August 2011) of "HTML5 differences from HTML4",[49] which provides a complete outline of additions, removals and changes between HTML5.

The W3C HTML5 logo

On 18 January 2011, the W3C introduced a logo to represent the use of or interest in HTML5. Unlike other badges previously issued by the W3C, it does not imply validity or conformance to a certain standard. As of 1 April 2011, this logo is official.[50]

When initially presenting it to the public, the W3C announced the HTML5 logo as a "general-purpose visual identity for a broad set of open web technologies, including HTML5, CSS, SVG, WOFF, and others".[51] Some web standard advocates, including The Web Standards Project, criticised that definition of "HTML5" as an umbrella term, pointing out the blurring of terminology and the potential for miscommunication.[51] Three days later, the W3C responded to community feedback and changed the logo's definition, dropping the enumeration of related technologies.[52] The W3C then said the logo "represents HTML5, the cornerstone for modern Web applications".[50]

See also

Template:Multicol

| class="col-break " |

|}

References

  1. ^ http://dev.w3.org/html5/spec/introduction.html#history-1
  2. ^ a b "HTML5 Differences from HTML4". Working Draft. World Wide Web Consortium. 5 April 2011. Introduction. Retrieved 30 April 2011. HTML 4 became a W3C Recommendation in 1997. While it continues to serve as a rough guide to many of the core features of HTML, it does not provide enough information to build implementations that interoperate with each other and, more importantly, with a critical mass of deployed content. The same goes for XHTML1, which defines an XML serialization for HTML4, and DOM Level 2 HTML, which defines JavaScript APIs for both HTML and XHTML. HTML5 will replace these documents. {{cite web}}: Check date values in: |date= (help); no-break space character in |date= at position 2 (help)
  3. ^ a b "HTML5 Differences from HTML4". World Wide Web Consortium. 19 October 2010. Retrieved 4 December 2010. {{cite web}}: Check date values in: |accessdate= and |date= (help); no-break space character in |accessdate= at position 2 (help); no-break space character in |date= at position 3 (help)
  4. ^ "1.9.2 Syntax Errors". HTML5. 16 November 2010. Retrieved 4 December 2010. {{cite web}}: Check date values in: |accessdate= and |date= (help); no-break space character in |accessdate= at position 2 (help); no-break space character in |date= at position 3 (help)
  5. ^ "HTML 4 Errata". World Wide Web Consortium. Retrieved 4 December 2010. {{cite web}}: Check date values in: |accessdate= (help); no-break space character in |accessdate= at position 2 (help)
  6. ^ "Frequently Asked Questions (FAQ) About the Future of XHTML". World Wide Web Consortium. Retrieved 4 December 2010. {{cite web}}: Check date values in: |accessdate= (help); no-break space character in |accessdate= at position 2 (help)
  7. ^ FOX News: No Flash on the iPhone? Apple's Steve Jobs Finally Explains Why
  8. ^ TIME: Steve Jobs: ‘Flash is No Longer Necessary’ and Other Musings
  9. ^ CBS News: Steve Jobs: Why Apple Banned Flash
  10. ^ FastCompany: Steve Jobs: Adobe's Flash Is Old PC History, Open Web Is the Future
  11. ^ "Thoughts on Flash", by Steve Jobs, CEO of Apple, Inc.
  12. ^ Is HTML5 Replacing Flash?
  13. ^ "[whatwg] WHAT open mailing list announcement". lists.whatwg.org Mailing Lists. Retrieved 4 March 2010.
  14. ^ "HTML5: A vocabulary and associated APIs for HTML and XHTML (Editor's Draft)". World Wide Web Consortium. Retrieved 12 April 2010.
  15. ^ "HTML5: A vocabulary and associated APIs for HTML and XHTML". World Wide Web Consortium. Retrieved 28 January 2009.
  16. ^ "When Will HTML5 Be Finished?". WHATWG. WHATWG Wiki. Retrieved 10 September 2009.
  17. ^ "HTML Working Group". World Wide Web Consortium. Retrieved 4 March 2010.
  18. ^ "HTML5". World Wide Web Consortium. 25 August 2009. Retrieved 4 March 2010.
  19. ^ "[whatwg] HTML5 at Last Call (at the WHATWG)". Lists.whatwg.org. Retrieved 4 March 2010.
  20. ^ "Dive Into HTML5".
  21. ^ a b c "When Will HTML5 Be Finished?". FAQ. WHAT Working Group. Retrieved 29 November 2009.
  22. ^ "HTML 5 Editor Ian Hickson Discusses Features, Pain Points, Adoption Rate, and More". Retrieved 21 June 2010.
  23. ^ Hickson, Ian. "WHATWG: Switching to an Unversioned Development Model". Retrieved 21 January 2011.
  24. ^ Hickson, Ian. "HTML Is the New HTML5". Retrieved 21 January 2011.
  25. ^ a b "W3C Confirms May 2011 for HTML5 Last Call, Targets 2014 for HTML5 Standard". World Wide Web Consortium. 14 February 2011. Retrieved 18 February 2011. {{cite web}}: Check date values in: |date= (help); no-break space character in |date= at position 3 (help)
  26. ^ Introduction to HTML5 video
  27. ^ IBM Developer Works New elements in HTML5: Structure and semantics
  28. ^ ICAMD.org Finalcut Silverlight Films that Videographers share Quicktime in a Flash : Video on the Web using HTML5 and other Codecs
  29. ^ InstantShift [1] HTML5: Worth the Hype?
  30. ^ "HTML5 Differences from HTML4 – APIs". World Wide Web Consortium.
  31. ^ "HTML Canvas 2D Context". World Wide Web Consortium.
  32. ^ "Web Storage Specification". World Wide Web Consortium.
  33. ^ "HTML5 Web Messaging". World Wide Web Consortium.
  34. ^ http://www.whatwg.org/specs/web-apps/current-work/multipage/introduction.html#is-this-html5?
  35. ^ "Web SQL Database". World Wide Web Consortium.
  36. ^ "Indexed Database". World Wide Web Consortium.
  37. ^ "File API". World Wide Web Consortium.
  38. ^ "Filesystem API". World Wide Web Consortium.
  39. ^ "File API: Writer". World Wide Web Consortium.
  40. ^ "What HTML5 is (and what it isn't)", HTML5 First Look, (lynda.com, 2010), <http://www.lynda.com/home/DisplayCourse.aspx?lpk2=67161>
  41. ^ Anne, van Kesteren. "HTML5 differences from HTML4 – W3C Working Draft 19 October 2010". World Wide Web Consortium. Retrieved 2 November 2010. {{cite web}}: Check date values in: |accessdate= (help); no-break space character in |accessdate= at position 2 (help); no-break space character in |title= at position 57 (help)
  42. ^ Sergey Mavrody "Sergey's HTML5 & CSS3 Quick Reference". Belisso Corp., 2010. ISBN 978-0615433219
  43. ^ "The XHTML syntax ― HTML5". Web Hypertext Application Technology Working Group. Retrieved 1 September 2009.
  44. ^ Polyglot Markup: HTML-Compatible XHTML Documents, W3C Working Draft 05 April 2011
  45. ^ a b "FAQ – WHATWG Wiki". WHATWG. Retrieved 26 August 2011.
  46. ^ "Percentage of Web sites Using HTML5". binvisions. Retrieved 21 October 2011. {{cite web}}: Cite has empty unknown parameter: |1= (help)
  47. ^ Kelly, Matt. "Introducing HTML5 Resource Center". Facebook. Retrieved 21 October 2011.
  48. ^ "HTML5: The Markup Language Reference: Input Control". World Wide Web Consortium. Retrieved 17 February 2011.
  49. ^ "HTML5 Differences from HTML4". FAQ. World Wide Web Consortium. 13 January 2011. Retrieved 23 January 2011.
  50. ^ a b "W3C HTML5 Logo FAQ". World Wide Web Consortium. Retrieved 21 January 2011. Is this W3C's "official" logo for HTML5? Yes, as of 1 April 2011. {{cite web}}: no-break space character in |quote= at position 54 (help)
  51. ^ a b "HTML5 Logo: Be Proud, But Don't Muddy the Waters!". The Web Standards Project. Retrieved 22 January 2011.
  52. ^ "The HTML5 Logo Conversation". World Wide Web Consortium. Retrieved 21 January 2011.

Further reading

Template:Multicol

| class="col-break " |

|}