当前位置:网站首页>BOM part attributes and understanding
BOM part attributes and understanding
2022-07-28 10:54:00 【Much less】
BOM Some attributes and understanding
BOM Call it the browser object model . It is mainly about the way we interact with browsers .
By IE3.0 and Netscape Navigator3.0( netscape ) Provides a new feature , It is mainly used to pass through JS This scripting language to operate the browser , It is convenient for us to access the browser window .
BOM Some objects contained in :
Window object
Navigator object
Screen object
History object
Location object
window( window ), Table 4 browser window , Top objects , All global variables belong to window
window.name The name of the current browser ( Can store several megabytes of content )
window.closed Closed window
window.opener Open window object
notes :
window.opener In the current window is the current window object , In a child window, it refers to the parent window of the child window
You can use window.opener.document.write( ) Wait for the operation
window.open( ) How to open a new window
notes :
For security reasons , The child window and the parent window can transmit data , If there is no need to communicate between the new window and the parent window , take opener Set to null.
How to write it :
var a=window.open();
a.opener=null;
attribute :
window.screenX,window.screenY
Current browser The upper left corner of the window Compared with when Front screen Horizontal distance and vertical distance of the upper left corner , The unit is Pixels , And the property is read-only
window.innerWidth,window.innerHeight
The current page is in the current window The visible part Width and height . That is commonly known as viewport "viewport".
The visible part :
But the reality part . If the window is half covered , The other half is the visible part , It's only half the height .
window.outerWidth,window.outerHeight
The width and height of the browser window
window.scrollX,window.scrollY
Horizontal distance and vertical distance of page scrolling
边栏推荐
- 10_ UE4 advanced_ Add fall and cast actions
- Blue Bridge Cup embedded Hal library systick
- samba服务器配置
- Pyqt5 rapid development and practice 4.12 calendar and time
- The 10th Landbridge cup embedded electronic provincial competition
- andorid 开发
- AP AUTOSAR platform design 3 architecture
- Blue Bridge Cup embedded Hal library LCD
- PyQt5快速开发与实战 4.12 日历与时间
- Pyqt5 rapid development and practice 4.13 menu bar, toolbar and status bar and 4.14 qprinter
猜你喜欢

Particle swarm optimization to solve the technical problems of TSP

Blue Bridge Cup embedded Hal library LCD

Advance.ai sailing guide helps enterprises sail to Indonesia and grasp half of the Southeast Asian market

Excel word simple skills sorting (continuous update ~)

产品端数据分析思维
Advanced C language: pointer (1)

Blue Bridge Cup embedded Hal library ADC

Configuring raspberry pie, process and problems encountered

蓝桥杯嵌入式-HAL库-USART_RX

MySQL Architecture Principle
随机推荐
GKNoiseMap
Lucene query syntax memo
盘点:144个免费学习网站,全网最全资源合集
产品端数据分析思维
数组相关的知识点
CRM+零代码:轻松实现企业信息化
10_ UE4 advanced_ Add fall and cast actions
GKNoiseMap
Blue Bridge Cup embedded Hal library USART_ RX
I don't know how lucky the boy who randomly typed logs is. There must be a lot of overtime
OCR 知识 概括
GKConstantNoiseSource
GKRandom
The future of generating confrontation networks in deepfake
Reading these six books makes learning MySQL easier
Ten questions about low code: tell everything about low code!
11_ UE4 advanced_ Change male characters to female characters and modify the animation
乱打日志的男孩运气怎么样我不知道,加班肯定很多
Learn how to do e-commerce data analysis (with operation analysis index framework)
一文学会如何做电商数据分析(附运营分析指标框架)