js基础对象-编程模式与设计模式
来源:互联网 发布:apache和nginx用哪个 编辑:程序博客网 时间:2024/05/16 09:54
1.常用BOM
window.navigator
window.location 属性href hash host hostname pathname port protocal search
window.history history.forward() history.back() history.go(-1) history.go(0)
window.frames获取当前页面是否存在frame元素,可以用索引来操作frames如window.frames[0] window.frames[0].window frames[0].window frames[0]如果frame元素 访问子frame元素属性,frames[0].window.location.reload()同时可以通过parent来访问父级页面,top属性可以访问顶级页面,self自身属性
screen包含浏览器以外的桌面信息
window.open() cloase()
window.moveTo() window.resizeTo() window.alert() window.prompt() window.confirm()
重要的两个时间函数
window.setTimeout() window.setInterval()
对应方法有clearTimeout() clearInterval()
document有的属性nodeType nodeName nodeText haschidNodes()判断是否有子节点
hasAttributes()方法检查该元素中是否存在属性
nextSiblng previousSibling树节点,firstChild lastChild两个属性
getElementsByTagName
DOM节点修改可以用nodeValue,innerHTML等
creatElement()和createTextNode()这两个方法创建新节点,appendChild()可以将新节点添加到DOM结构中
createTextNode创建文本节点
cloneNode()
insertBefore()
removeChild()
访问文档的基本方法
document.images
documentllinks
document.anchors
doucment.forms
获取当前页面的表单document.forms[0]
如果form有name属性的话,可以document.forms[0].elements['search']来查找
document.write()
Cookies Title Referrer Domain
addEventListener
停止冒泡:stopPropagation
编程模式
1.行为隔离
2.命名空间
var MYAPP=MYAPP || {};
- js基础对象-编程模式与设计模式
- js 设计模式 oop 面向对象编程
- js 设计模式 oop 面向对象编程
- js 设计模式 oop 面向对象编程
- js设计模式基础
- JAVA基础--网络编程与设计模式
- js设计模式---面向对象
- js创建对象 设计模式
- 设计模式:面向对象基础
- 【设计模式】面向对象基础
- 面向对象设计模式基础
- 【编程基础】Adapter设计模式
- 编程基础之设计模式
- PHP设计模式(一):基础编程模式
- 设计模式之面向对象与类基础特征概念
- 初探面向对象编程之oop与设计模式
- 设计模式与面向对象
- 面向对象与设计模式
- skia draw path flow
- shareSDK社会化分享
- 使用EJB使用jboss7.0中配置数据源
- crtmpserver基本架构(协议和服务对应关系)
- 生产计划执行系统或任务系统构建
- js基础对象-编程模式与设计模式
- 文章标题
- HDU 1002 A + B Problem II (大数加法)
- Halcon学习 多层神经网络
- Unity3D-个人学习的道路
- CheckBox滑动后乱序
- php mysql_query 返回值
- Swift中闭包(closure)的使用
- C数据结构学习历程(1) 顺序表