目录
一、html标签
整个网页项目都是写在html主标签中,它属于一个跟标签
<!DOCTYPE html>
它表示的是使用html5的标准对文档进行编译
二、head标签
head标签引入与网页相关的描述及配置信息,其中的meta标签负责信息引入与说明,有name和http-equiv两个属性。
1、meta标签
<meta charset="UTF-8">
用于对网页进行utf-8翻译
<meta name="keywords" content="test,c1,html">
keywords 网页的关键词,对整个网页内容的提炼说明,利于爬虫对数据的爬取
<meta name="description" content="this is a test web">
description 网页的描述,说明整个网页具体是做什么的
<meta name="author" content="作者">
author 网页的作者备注
<meta name="viewport" content="width=device-width, initial-scale=1.0">
viewport 移动端约束
<meta name="viewport" content="width=device-width, initial-scale=1.0">
宽度等于设备的宽度,元素初始化缩小比例1.0,为了满足移动端的约束,防止页面变形。
2、link标签
link标签可以用来引入外部样式表。
<link rel="stylesheet" href="css/test.css">