学习标签:
<p></p>
<h1></h1>
…
<h6></h6>
<del></del>//斜体加粗
<address></address>
<br> <hr>
<ul> //整个为一体 网页中常见 书柜与书的关系
<li></li>
<li></li>
</ul>
行级标签<<span></span><em></em><del></del>
块级标签<div></div><p></p>
特殊标签<img src="“alt=“图片占位符"title=“图片提示符 “></img>//图片显示 src 资源定位 alt
路径:
网上url:网上路径
绝对路径:不同文件夹下
相对路径:html文件与图片在相同文件夹
<a href=”” target=“blank”>
作用:
超连接 href=“www.baidu.com”
锚点 href=”#”
打电话 href=“tel:12399485555”
协议限定符 href=‘运行javascript代码’
html格式:
<html>
<head>
<mete charset=‘utf-8’> //字符编码设置为万国语言 中英文不乱码
<title>网址名称</title>
<body>
html 开发代码骨架
</body>
</head>
</html>
<form method=“get” action="">数据发送
method 数据发送方
{
get:
post:
}
action 数据接收方地址
{
}
输入
input< type="text/password属性格式文本/密文"name=“属性名"value=“属性值”>
提交
input< type=“submit"name=””>
选项
input< type=‘radio’ name=’’>//单选 名一样 多选名不一样 值需定义
type 功能很多 checkbox 复选框
例题:导航栏
username: <input type="text" name="name" value="请输入关键字"
onfocus="if(this.value=='请输入关键字'){this.value='';}"
onblur="if(this.value==''){this.value='请输入关键字';}"> //两个判断
password: <input type="password" name="password" >
<input type="submit" >
</from>
标签:复选栏
<select>
<option></option>
</select>
shell 内核
ie trident
firefox gecko
google blink
safari webkit
opera presto
css:
行间样式:
<div style=""></div>
页面级样式:
<head>
<style type=“text/css”></style>
div{
width:100px;
heigth:100px;
background-color:100px;
}
</head>
外部css文件:
ccs文件名
在head标签内写link标签<link rel=“stylesheet” type=“text/css” href=“csss文件名.css”>
id选择器
id=“on” #on{ ccs代码} 一一对应
class选择器
class=“in” .in{css代码} 多对多
标签选择器
权重: 256进制
!important 无穷
行间样式 1000
id: 100
class || 属性选择器: [id=""] ||伪类 10
标签 || 伪元素 1
通配符: 0
属性选择器: [id=""] {css代码}
父子选择器 -->嵌套
直接子元素选择器 div > em 直接隶属才生效
并列选择器 em .class{css代码}
分组选择器 例如 em,strong,span{css代码}
css内容:
font-size 字体尺寸
font-weigth:bold lighter normal bolder 100-900 加粗
font-style:italic 斜体
font-family:arial 字体
color: 颜色英语单词 颜色代码 颜色函数 补充透明色transparent
border:1px solid/dotted/dashed red; 大小形状颜色 border特殊说明 可独自设立单边