<ul></ul>:无序列表
可使用css样式
ul:
设置列表样式类型为没有删除列表项标记
设置填充和边距0px(浏览器兼容性)
ul中所有li:
设置图像的URL,并设置它只显示一次(无重复)
您需要的定位图像位置(左0px和上下5px)
用padding-left属性把文本置于列表中
<html>
<head>
<mate charset='utf-8' />
<style type="text/css">
ul{
list-style-type: none;
padding: 0px;
margin: 0px;}
ul li {
background-image: url(/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=1454783519,2870582753&fm=26);
background-repeat: no-repeat;
background-position: 0px 5px;
padding-left: 14px; }
</style>
<title>
yifachen </title>
</head>
<body>
<ul>
<li>python</li>
<li>java</li>
<li>c++</li>
</ul>
</body></html><table></table>:表格标签
<table>标签定义html表格
表格由tr th td组成
tr:元素定义表格行
th:元素定义表头
td:元素定义表格单元
table标签有以下属性:
border属性:定义表格边框的宽度 单位px
cellspacing属性:定义单元格之间的空白 单位px
cellpadding属性:定义边沿与内容之间的空白 单位px
width属性:定义表格宽度
height属性:定义表格高度
tr th td 标签有以下属性:
colspan属性:number(随意定义数字) 定义横跨列数(左右合并)
rowspan属性:number(随意定义数字) 合并横跨行数(上下合并)
快速生成表格 tr*3 按tab
<html> <head> <mate charset='utf-8' /> <title> yifachen </title> </head> <body> <table border="" cellspacing="0px" cellpadding="10px" width="10px" height="10px"> <tr> <th rowspan="2">dcs</th> <th>姓名</th> <!--th*3 按tab 快速生成--> <th>年龄</th> <th>性别</th> <th>语言</th> </tr> <tr> <td>youzi</td> <td>28</td> <td>男</td> <td>python</td> </tr> </table> </body></html>
<form></form>:表单标签
action属性:规定当提交表单时向何处发送表单数据
method属性:规定请求以get还是post的方式发送
type属性:text为明文 password为密文
<!DOCTYPE html><html> <head> <meta charset="UTF-8"> <title> yifachen </title> </head> <body> <form action="http://www.baidu.com">User name:<br /> <input type="text" name='username' id='usrid'/><br /> Pass word:<br /> <input type="password" id="pwdid" /><br /><br /> <button>提交</button> </form> </body></html>
<lable></lable>:input元素定义标签
type属性:定义input标签 等于radio时为单选框 等于checkbox为复选框 等于file时为上传文件
name属性:等于sex时可避免同时选择两个值
checked属性:表示默认选择的值
<!DOCTYPE html><html> <head> <meta charset="UTF-8"> <title> yifachen </title> </head> <body> <form action="http://www.baidu.com" method="post" >User name:<br /> <input type="text" name='username' id='usrid'/><br /> Pass word:<br /> <input type="password" id="pwdid" /><br /><br /> <lable><input type="radio" name="sex" />男</lable> <lable><input type="radio" name="sex" checked=""/>女</lable><br /><br /> 你喜欢的游戏是?<br /> <lable><input type="checkbox" />LOL</lable> <lable><input type="checkbox" />PUBG</lable> <lable><input type="checkbox" checked=""/>DNF</lable><br /> <lable><input type="file" /></lable><br /> <button>提交</button> </form> </body></html>
<textarea></textarea>:标签定义多行的文本输入控件 文本域
cols属性:传输number类型数据 规定文本域内可见宽度
rows属性:传入number数据类型 规定文本域内可见行数
<!DOCTYPE html><html> <head> <meta charset="UTF-8"> <title> yifachen </title> </head> <body> <form action="http://www.baidu.com" method="post" >User name:<br /> <input type="text" name='username' id='usrid'/><br /> Pass word:<br /> <input type="password" id="pwdid" /><br /><br /> <lable><input type="radio" name="sex" />男</lable> <lable><input type="radio" name="sex" checked=""/>女</lable><br /><br /> 你喜欢的游戏是?<br /> <lable><input type="checkbox" />LOL</lable> <lable><input type="checkbox" />PUBG</lable> <lable><input type="checkbox" checked=""/>DNF</lable><br /> <lable><input type="file" /></lable><br /> <textarea name="textarea" rows="5" cols="50" >我是一个文本域</textarea><br /> <button>提交</button> </form> </body></html>
<select></select>下拉框标签
<!DOCTYPE html><html> <head> <meta charset="UTF-8"> <title> yifachen </title> </head> <body> <form action="http://www.baidu.com" method="post" >User name:<br /> <input type="text" name='username' id='usrid'/><br /> Pass word:<br /> <input type="password" id="pwdid" /><br /><br /> <lable><input type="radio" name="sex" />男</lable> <lable><input type="radio" name="sex" checked=""/>女</lable><br /><br /> 你喜欢的游戏是?<br /> <lable><input type="checkbox" />LOL</lable> <lable><input type="checkbox" />PUBG</lable> <lable><input type="checkbox" checked=""/>DNF</lable><br /> <lable><input type="file" /></lable><br /> <textarea name="textarea" rows="5" cols="50" >我是一个文本域</textarea><br /> <select > <option value="iphone">iphone</option> <option value="andriod">andriod</option> <option value="ios">ios</option> </select><br /> <button>提交</button> </form> </body></html>
<button></button>标签
type属性 等于submit时为提交 等于reset为重置 等于button时只是单纯的一个可点击的按钮
<!DOCTYPE html><html> <head> <meta charset="UTF-8"> <title> yifachen </title> </head> <body> <form action="http://www.baidu.com" method="get" >User name:<br /> <input type="text" name='username' id='usrid'/><br /> Pass word:<br /> <input type="password" id="pwdid" /><br /><br /> <lable><input type="radio" name="sex" />男</lable> <lable><input type="radio" name="sex" checked=""/>女</lable><br /><br /> 你喜欢的游戏是?<br /> <lable><input type="checkbox" />LOL</lable> <lable><input type="checkbox" />PUBG</lable> <lable><input type="checkbox" checked=""/>DNF</lable><br /> <lable><input type="file" /></lable><br /> <textarea name="textarea" rows="5" cols="50" >我是一个文本域</textarea><br /> <select > <option value="iphone">iphone</option> <option value="andriod">andriod</option> <option value="ios">ios</option> </select><br /> <button type="reset">重置</button> <button type="submit">提交</button> <button type="button">单纯的按钮</button> </form> </body></html>