"Top.location.href" is the outermost page jump
"Window.location.href", "location.href" is this page jump
"Parent.location.href" is a page jump on the previous level.
The location is a property of the Window object, and all the objects under the page are in the window scope chain (this is the top-level scope), so you can omit window when you use it. The top is a pointer to the top-level window object, and the parent is a pointer to the Window object.
Window.location is a property of the Window object, and Window.Open is a method of the Window object
Window.location is your reference to the URL address object of the current browser window!
Window.Open is a function to open a new window!
window.open () is the address of another website that can be opened on one website
and Window.location () is a Web page that can only be opened on a Web site.
Window.location or window.open How do I specify target?
This is a frequently encountered problem, especially when using frame frames.
Workaround:
Window.location to Top.location can be linked to a specified page at the top
Or
window.open ("Your url", "_top");
<input type= "button" value= "New window opens" onclick= "window.open (' http://www.baidu.com ')" >
<input type= "button" value= "current page open" onclick= "top.location= ' http://www.baidu.com ', ' _top '" >
The difference between window.location and window.open ()