Window name attribute
- Taima ɗanɗi moveTo()
- Taima ɗanɗi navigator
- Taima ɗanɗi Window Obhaji
Definition and usage
name
Set or return the name of the window attribute.
Hint:The window does not need to have a name.
Instance
Example 1
Get window name:
let name = window.name;
Example 2
Set window name:
window.name = "myWindowName";
Example 3
Open a frame with a special name:
const otherWindow = window.open(); otherWindow.name = "Butterfly";
Grammar
Return name attribute:
window.name
Sedate name attribute:
window.name = winName
Attribute value
Attribute value | Description |
---|---|
winName | The name of the window. |
Return value
Type | Description |
---|---|
String |
The name of the window. If the window has no name, it returns |
Browser support
All browsers support window.name
:
Chrome | IE | Edge | Firefox | Safari | Opera |
---|---|---|---|---|---|
Chrome | IE | Edge | Firefox | Safari | Opera |
Support | Support | Support | Support | Support | Support |
- Taima ɗanɗi moveTo()
- Taima ɗanɗi navigator
- Taima ɗanɗi Window Obhaji