46 lines
775 B
Markdown
46 lines
775 B
Markdown
# html基本结构
|
|
|
|
* demo1
|
|
```
|
|
<!doctype html> <!--文档声明--> (<!--这是注释的内容-->)
|
|
<html>
|
|
<head>
|
|
<title>这是html基本结构</title> <!--这是浏览器标签栏上的标题 -->
|
|
</head>
|
|
<body>
|
|
...页面内容
|
|
</body>
|
|
</html>
|
|
```
|
|
|
|
* demo2
|
|
```
|
|
<!doctype html>
|
|
<html>
|
|
<head>
|
|
<title>这是html基本结构</title>
|
|
<meta charset="UTF-8"> <!-- 解决乱码 -->
|
|
</head>
|
|
<body>
|
|
...页面内容
|
|
</body>
|
|
</html>
|
|
|
|
```
|
|
|
|
* demo3
|
|
```
|
|
<!doctype html>
|
|
<html>
|
|
<head>
|
|
<title>这是html基本结构</title>
|
|
<meta charset="UTF-8">
|
|
<link rel="stylesheet" href="style.css">
|
|
</head>
|
|
<body>
|
|
...页面内容
|
|
</body>
|
|
</html>
|
|
|
|
```
|