English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية
focus()The method requests to bring the window to the foreground (close to the screen).
Usageblur()The method removes the focus from the current window.
window.focus()
var popupWindow = window.open("https://www.oldtoolbag.com"); popupWindow.focus();Test See‹/›
All browsers fully support the focus() method:
Method | |||||
focus() | Yes | Yes | Yes | Yes | Yes |
Return Value: | None |
---|
Window (Window) Reference:blur() method