HTML5 is the next version of the HTML standard. Although HTML5 did not completely subvert HTML4, they were somewhat different. The latest and most complete HTML5-HTML4 comparison information please see http://dev.w3.org/html5/html4-differences/, looks slightly more appearance. In this IE still exist in the world, the difference of HTML5 first grasp some can, and so on all support then carefully study also not late.
1. Simplified syntax
HTML5 simplifies a lot of subtle syntax, such as DOCTYPE's declaration, you just have to write <!doctype html>. HTML 5 Specifies UTF-8 encoding in the following way <meta charset= "UTF-8" >
2. <canvas> tag instead of Flash
Flash brings trouble to many web developers, and it requires a bunch of code and plugins to play flash on a Web page. <canvas> tags make it possible for developers to interact with the user UI with a single tag.
3 Many new tags added
One of the principles of HTML5 design is to better reflect the semantics of the site, so add
Copy CodeThe code is as follows:
<video width= "height=" 340 "controls>
<source src= "Jamshed.mp4" type= "Video/mp4" >
Your Browser does ' NT support video embedding feature.
</video>
Similarly, audio and other things are similar.
4. A new form
HTML5 has made a lot of changes to <form> and <forminput> tags, added a lot of new properties, and modified many properties, detailed http://www.jb51.net/w3school/html5/html_5_ Form_attributes.htm
5. Delete <b> and <font> tags, <frame>, <center>, <big> tags
6.HTML5 supports different types of storage types
HTML5 supports local storage, which is implemented through cookies in previous versions. HTML5 Local storage is fast and secure. And HTML5 has two different objects that can be used to store data and HTML5 to store and access data via JS:
Localstorage for long-term storage of data, no loss of data after browser shutdown
Sessionstorage is only for a session of the data store, the stored data is automatically deleted after the browser is closed
In general, HTML5 has gone beyond the realm of markup language, and a more semantic label will make HTML5 more useful. Canvas+webgl and other technology, to achieve non-plug-in animation and image, graphics processing capabilities, local storage, can achieve offline applications, WebSocket, a pure pull model of HTTP, to achieve the dream of data push, Mathml,svg, Support for a richer render and so on, and so on, now for the understanding of HTML5 only to stay on the surface stage, will read more part of the HTML5 of the book to add a bit of insight.
The difference between HTML5 and HTML4