Home > Web Front-end > HTML Tutorial > What is the difference between HTML and HTML5?

What is the difference between HTML and HTML5?

Guanhui
Release: 2020-06-12 14:28:34
Original
5381 people have browsed it

What is the difference between HTML and HTML5?

What is the difference between HTML and HTML5?

1. HTML does not have tags that reflect structural semantics, but HTML5 has many semantic tags;

HTML: There are no tags that reflect structural semantics. We usually The

<div id="header"></div>
Copy after login

named in this way represents the head of the website.

HTML5: It has great advantages in semantics. Some new html5 tags are provided, such as:

<header> 、<nav>、<article>、<aside>、<footer>
Copy after login

2. HTML is a plain text language, and HTML5 can make document declarations, which is beneficial for developers to quickly read and develop.

HTML:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "
http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
Copy after login

HTML5:

 <!DOCTYPE html>
Copy after login

It can be seen from the comparison between the two: in the document declaration, html has a long section of code, and it is difficult to remember this This piece of code must be generated directly by many people using tools, right? But html5 is different. It only has simple declarations, which is also easier for people to remember and is more streamlined.

Recommended tutorial: "HTML Tutorial"

The above is the detailed content of What is the difference between HTML and HTML5?. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template