14th Chapter Window Object
1. The Document object has a URL attribute, which is a static string that holds the URL of the documents when the document is first loaded. If you navigate to a fragment identifier in a document, the locationobject makes the corresponding update , and document. The URL property does not change .
2. The Location property of the Window object refers to the position object, which represents the URL of the document currently displayed in the window.
3. A purely fragment identifier is a type of relative URL that does not let the browser load a new document, but only scrolls it to a location in the document. If the ID of a document without an element is top, he will be the browser jumping to the beginning of the document.
4. The History property of the Window object refers to the history object of the Windows.
5. The Navigator property of the Window object refers to the Navigator object that contains the browser manufacturer and version information.
6, methods confirm () and prompt () will cause blocking , that is, they will not return until the user turns off the dialog box they display.
7. The alert () method also causes blocking and waits for the user to close the dialog box, but not always.
8, ShowModalDialog () displays a modal dialog box that contains HTML formatting.
9. Use the Open () method of the Window object to open a new browser window or tab.
10. The script can specify the existing window by its name only if the document contained in the window is from the same source or if the script opens the window.
11.The return value of open () is the Window object that represents the named or newly created Windows .
12. Normally, the open () method is called only when the user clicks the button or link manually.
13. The <iframe> element has the Contentwindow attribute, which refers to the Widnow object of the form (also with the contentdocument property).
14. Each Window object has a frames property that references the child window of the window it contains, andthe frames property refers to the class array object and can be indexed by a number or window name.
15. If you specify the name or id attribute of the <iframes> element, you can index it by name in addition to the number index.
16, each window has its own string () constructor and a copy of the String.prototype object. Therefore, the string class for different Windows does not share a new method defined within a window .
js-Authoritative Guide Study notes 14