javaScript属性

------------------------------------行内样式------------------------------------
 *基本标签
html 网页的开始标记
head 网页的头部标记
body 网页的主体标记
bgcolor: 背景色;
background 背景图片
title 整个网页的标题
例如<p style="color:red"></p>
*img 图像标签:
src 图像的保存路径
width 宽度
height 高度
alt 图像的替代文字
*font 字体标签:
size 字体的大小1~7
color 颜色
face 字体的类型
*p 段落标签:
align 段落的水平对齐方式left/center/right
*h1~h6 标题标签:
*hr 水平分割线:
*ol 有序列表:
li 列表项
type 列表项目符号的类型
ul 无序列表:
dl 定义描述标签
*a 超链接:
name 锚记名
href 链接的目标位置
<a href="#Jane">点击去</a>
<a name="Jane" href="#">到这</a>
*背景相关属性:
背景颜色
background-image:"a.jpg"; 背景图片
background-repeat:no-repeat; 背景重复方式
background-position 背景偏移
----------------------------------------内部样式------------------------------------
样式表部分
style 风格
css中文本相关属性:
color 字体颜
*文本属性:
font-size :30px;字体大小
font-family :隶书;字体类型
font-style :italic/normal
font-weight:bold; 是否加粗
text-align:left/center/right 水平对齐方式
line-height:33px;行高
letter-spacing:1px; 字符间距
text-decoration 是否出现下划线underline/none
*盒子模型属性:
零散属性:
width 宽度 
height 高度
*边框属性:
border-width 边框粗细
border-style 边框线型 
solid:实线
dashed:虚线
dotted:点线
border-color 边框颜色
*边框属性:
border:1px solid red;
border-top/right/bottom/left:
border-边框粗细(单位是px);
border-style:边框线型(solid 实线;dashed 虚线);
border-color:边框颜色
*填充属性(内部距离):
padding-top:5px;上填充
padding-right:右填充
padding-bottom:下填充
padding-left:左填充
*边界属性(外部距离):
margin-top:1px;上外边界
margin-right:右外边界
margin-bottom:下外边界
margin-left:左外边界
*列表属性:
list-style:none;
如何引入外部样式表?
<link type="text/css" rel="stylesheet" href="外部样式文件的路径"/>
-----------------------------------------方法修改样式------------------------------------
function mouseOver(tr){
bc=tr.style.backgroundColor; //背景色
fc=tr.style.color; //前景色
tr.style.backgroundColor="#000";//背景色
tr.style.color="#fff";//前景色
}
---------------------------------------表格部分------------------------------------
*table 表格标签
tr 行标签
td 单元格标签
colspan 跨列
rowspan 跨行
*border 表格边框
bordercolor 边框颜色
cellspacing 单元格之间的间隙
*表格高级标签:
thead 表头标签
tbody 表格的主体
tfoot 表尾
*th 列的标题 (与td同级别)
caption 表格的标题
*属性的设置(表的行内样式)
cellspacing="0"表格的格子之间的距离
cellpadding="3px"内部文字和格子边框的距离
---------------------------------------表单部分---------------------
*form 表单容器
name 表单的名字
method 表单提交方式 get/post
action 表单提交位置
*input 常见表单元素:
type 表单元素的类型
1、text 文本框 
name 表单元素的名称
value 初始值
size 文本框宽度
maxlength 最多可输入的字符个数
2、password 密码框
3、radio 单选按钮 
checked 按钮选中
value 提交到服务器的值
4、checkbox 复选框
cb[i].checked = false;
5、reset 重置按钮
value 按钮上的文字
6、submit 提交按钮
7、image 图像提交按钮
8、button 普通按钮
9、file 文件上传域
10、hidden 隐藏域
11、select 下拉列表
option 下拉列表的选项
selected 选项被选中
12、textarea 多行文本框
rows 多行文本框高度
cols 多行文本框宽度
readonly 只读
---------------------框架---------------------------
frameset 框架集标签
rows 上下划分
cols 左右划分
frameborder 框架集的边框
frame 框架标签
src 网页的路径
name 框架的名字
noresize 禁止改变框架窗口的大小
scrolling 是否出现滚动条
--------------------其它----------------------------------
visibility:visible;hidden(隐藏,被隐藏的页面元素仍然占位)

display:block;inline;none(隐藏,被隐藏的页面元素不占位)

原文地址:https://www.cnblogs.com/janesyf/p/7840957.html