一、BOM基础
1、打开:open
2、关闭:close
3、常用属性
window.navigator.userAgent 当前浏览器版本信息
window.location 路由信息
4、窗口尺寸、工作区尺寸
可视区尺寸
document.documentElement.clientWidth
document.documentElement.clientHeight
滚动距离
document.body.scrollTop
document.documentElement.scrollTop
二、常用方法和事件
1、系统对话框:
警告框:alert(“内容”),没有返回值
选择框:confirm(“提问的内容”),返回boolean
输入框:prompt(),返回字符串或null
2、window对象常用事件
onload
onscroll
onresize