English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية
HTML5is a language description method for constructing Web content. HTML5is the next generation standard of the Internet, a way of constructing and presenting Internet content. It is considered one of the core technologies of the Internet. HTML was born in1990 year,1997Year HTML4has become an Internet standard and is widely used in the development of Internet applications.
HTML5is the latest revision of HTML,2014Year10Month by the World Wide Web Consortium (W3C) completes the standard formulation.
HTML5The design purpose is to support multimedia on mobile devices.
HTML5is the specification of the core language HTML in the Web, which is the original content displayed to users when they browse the web with any means, and is converted into recognizable content through some technical processing in the browser
HTML5 simple and easy to learn.
HTML5 is the next generation HTML standard.
HTML, HTML 4.01The previous version of 1999 Year. Since then, the Web world has undergone tremendous changes.
HTML5 is still in the process of improvement. However, most modern browsers have already achieved some HTML5 Support.
HTML5 is W3C's collaboration with WHATWG, WHATWG refers to the Web Hypertext Application Technology Working Group.
WHATWG is committed to web forms and applications, while W3C focused on XHTML 2.0. In 2006 Year, both parties decided to cooperate to create a new version of HTML.
HTML5 Some interesting new features in it:
The canvas element for painting
The video and audio elements for media playback
Better support for local offline storage (localStorage and sessionStorage)
New special content elements, such as article, footer, header, nav, section
New form controls, such as calendar, date, time, email, url, search
HTML5Brings the Web into a mature application platform, where video, audio, images, animations, and interactions with devices are standardized.
The <!doctype> declaration must be located within HTML5 The first line in the document, using it very simply:
<!DOCTYPE html>
This will make the currently unsupported HTML5browsers adopt the standard mode for parsing, which means they will parse those HTML5part of the compatible old HTML tags while ignoring those they do not support HTML5new features.
This doctype is shorter and simpler than before, making it easier to remember and reduce the number of bytes that need to be downloaded.
The first thing to do on a page is usually to declare the character set used. In previous versions of HTML, it was a very complex <meta> element, but now it has become very simple:
<meta charset="UTF-8">
Put this in your <head>, because in some browsers if the declared character set is different from their expectations, they will reparse the HTML document. In addition, if you are currently not using UTF-8, it is recommended that you change your web page to this encoding because it simplifies the handling of characters in files by different scripts.
It is worth noting that HTML5Limited the available character sets, they need to be compatible8ASCII. This is done to enhance security and prevent certain types of attacks.
The following is a simple HTML5Document:
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>I am an html5Document title</title> </head> <body> html5Document content...... </body> </html>
Note: For Chinese web pages, you need to use <meta charset="utf-8"> Declare the encoding, otherwise garbled characters may appear.
New elements
New properties
Fully supports CSS3
Video and Audio
2D/3D mapping
Local storage
Local SQL data
Web application
Use HTML5 You can simply play video(video) and audio(audio) on the web page.
Use HTML5 You can simply develop applications
Local data storage
Access local files
Local SQL data
Cached reference
Javascript worker
XHTMLHttpRequest 2
Use HTML5 You can simply draw graphics:
New selectors
New properties
Animation
2D/3D transformation
Rounded corners
Shadow effects
Downloadable fonts
Learn more about CSS3Knowledge please refer to this site's CSS3 Tutorial.
HTML5 Added many semantic elements as shown below:
Tag | Description |
<article> | Define an independent content area of the page. |
<aside> | Define the sidebar content of the page. |
<bdi> | Allows you to set a piece of text so that it does not follow the text direction setting of its parent element. |
<command> | Define command buttons, such as radio buttons, checkboxes, or buttons |
<details> | Used to describe the details of a document or a part of it |
<dialog> | Define a dialog, such as a prompt box |
<summary> | The title containing the details element |
<figure> | Specifies independent flow content (images, charts, photos, code, etc.). |
<figcaption> | Defines the title of the <figure> element. |
<footer> | Defines the footer of a section or document. |
<header> | Defines the header area of the document. |
<mark> | Defines text with a label. |
<meter> | Defines a measurement. Used only for measurements with known maximum and minimum values. |
<nav> | Defines part of a navigation link. |
<progress> | Defines the progress of any type of task. |
<ruby> | Defines ruby annotations (Chinese phonetic or characters). |
<rt> | Defines the explanation or pronunciation of characters (Chinese phonetic or characters). |
<rp> | Used in ruby annotations, defines the content displayed by browsers that do not support ruby elements. |
<section> | Defines a section (section, division) in the document. |
<time> | Defines a date or time. |
<wbr> | Specifies where in the text it is appropriate to add a line break. |
New form elements, new attributes, new input types, and automatic validation.
The following HTML 4.01 elements in HTML5has been deleted:
<acronym>
<applet>
<basefont>
<big>
<center>
<dir>
<font>
<frame>
<frameset>
<noframes>
<strike>
With our HTML editor, you can edit HTML and then click the button to view the result.
<!DOCTYPE HTML> <html> <head> <meta charset="utf-8"> <title>Basic Tutorial Website(oldtoolbag.com)</title> </head> <body> <video width="320" height="240" controls> <source src="movie.mp4" type="video/mp4"> <source src="movie.ogg" type="video/ogg"> Your browser does not support the video tag. </video> </body> </html>Test and see ‹/›
The latest versions of Safari, Chrome, Firefox, and Opera support certain HTML5 features. Internet Explorer 9 will support some HTML5 features.
IE9 The following versions of browsers are compatible with HTML5methods, use the static resources of this site's html5shiv package:
<!--[if lt IE 9]> <script src="http://apps.bdimg.com/libs/html5shiv/3.7/html5shiv.min.js"></script> <![endif]-->
After loading, initialize the CSS for the new tags:
/*html5*/ article,aside,dialog,footer,header,section,nav,figure,menu{display:block}
You can find information about HTML5 Description of tags and attributes, for more details please click HTML5Reference Manual.