目录
  1. 1. 1 标签
html

1 标签

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
<!--输入html或者html5后空格可以自动生成模板-->
<html>
<head>
<title>第一个html </title>
</head>
<body>
<!--font是字体 ,size最大显示7
在HTML4中,不赞成使用该标签
在HTML5中,不支持该标签
-->
<!--标题越靠近body越容易被搜索引擎抓取-->
<h1>标题1</h1> <!--标题默认独占一行-->
<h2>标题2</h2>

<font size = "5" face="黑体" color="blue">
这是第一个页面
</font>

<!--锚点,用来在页面内快速跳转-->
<p><a href="#num-1">锚点1</a></p>
<!--可以打开其他html中的锚点-->
<p><a href="xxx.html#num-1">锚点1</a></p>



<!--锚点定位到这里-->
<a name="num-1">
<p>
第二段
<!--BR是换行不换段。-->

<!--../是返回上一级-->
<!--打开图片-->
<img src="平级或者绝对路径" alt="显示失败时的提示" width="" height="">

<!--打开外网要加http://-->
<a href="页面网址或者图片地址">页面显示的字</a>

<!--用图片打开网址-->
<a href="页面网址或者图片地址" target="_blank" >页面显示的字<img src="图片位置"> </a>

<!--列表项内部可以使用段落、换行符、图片、链接以及其他列表等.-->
<!--无序列表,可以li*5便捷写法-->
<ul>
<li>1</li>
<li>2</li>
</ul>
<ol>
<li>1</li>
<li>2</li>
</ol>

<!--插入表格-->
<!--颜色设置有多种方式,但是RGB已经不太用了,如果一定要使用,加style = "background-color:rgb(100,100,100);"-->
<table border="1" width="50%"><!--width也可以用Px表示像素-->
<!--tr表示行,td表示每个格子-->
<tr>
<td rowspan="2">1</td><!--行合并,往下合并单元格-->
<td>1</td>
<td>1</td>
</tr>
<tr>

<td>1</td>
<td>1</td>
</tr>
<tr>
<td colspan="3">1</td><!--列合并,往右合并单元格-->
</tr>
</table>


<!--表单-->
<!--action是存储位置,method是传入后台的提交方式-->
<form action="aaa" method="post">
<label>请输入姓名</label>
<input type="text" name="" id="">
<label>请输入性别</label>
<!--name设置为相同时属于同一组,按钮只能选中其一-->
<input type="radio" name="xb" id="" value="男">
<input type="radio" name="xb" id="" value="女">
<label>请输入生日</label>
<select>
<option value="1995">1995</option>
<option value="1996" selected="selected">1995</option>
</select>
头像<image src="图片位置" >
<select><!--下拉列表框-->
<option value="图片名字">图片名字</option>
<option value="图片名字">图片名字</option>
</select>
<input type="button" name="普通按钮">
<input type="submit" name="提交按钮">
</form>


<!--多行文本框-->
<textarea rows="" cols="" name="" id="">
请输入
</textarea>

<!--选择文件上传-->
<input type="file" name=""><input type="" value="上传">

<!--隐藏域-->
000<input type="" name="">000

</p>>
<a/>
</body>
</html>
image-20200307212908180

表格的其他标签

image-20200318182350529
文章作者: liuDH
文章链接: http://yoursite.com/2020/03/07/html/
版权声明: 本博客所有文章除特别声明外,均采用 CC BY-NC-SA 4.0 许可协议。转载请注明来自 毛毛裤裤的世界
打赏
  • 微信
  • 支付寶