Javasrcipt -- bom

Source: Internet
Author: User

Window

-Document
-Anchors
-Forms
-Images
-Links
-Location
-Frames
-History
-Location
-Navigator
-Screen

Window dialog box
Alert () displays a warning box with a message and a confirmation button.
Prompt () displays a dialog box that prompts you to enter.
Confirm () displays a dialog box with a message, a confirmation button, and a Cancel button.

Document attributes
Alinkcolor activation link color
Connection color accessed by vlinkcolor
Linkcolor link color
Bgcolor page background color
Fgcolor page text color
Lastmodified date of the last modification page
The URL of the last position in the referrer browser history
Title
URL: the URL of the current page

Document Method
Document. Write ()
Document. writeln () adds a line break (\ n) to the end of the string)
Document. open ()
Document. Close ()

VaR onewwin = Window. Open ("about: blank", "newwindow", "Height = 150, width = 300, Top = 10, Left = 10, resizable = yes ");
Onewwin.doc ument. open ();
Onewwin.doc ument. Write ("<HTML> Onewwin.doc ument. Write ("<body> tttttttttttttttttt </body> <HTML> ");
Onewwin.doc ument. Close ();

Document Set
-All anchors
-Forms form set
-Images image set
-Links link set
-Embeds embedded object set
Document. Images [0]; document ["name"];

 

History Object
Go ();
Back ();
Forward ();
Length

Location object
Attribute
Http://www.feng.com/pic/index.html
Hash # and post-number content
Host www.feng.com
Hostname feng.com
Complete URL of the current href page
Pathname/PIC/index.html
Port
Protocol get // previous content
In the search URL? And later neir
Method
Assign ("url") Load page
Replace ("url") loads pages, but cannot be viewed from history
Reload () True indicates that the load is from the server, and false indicates that the load is from the browser cache.

Screen Object
Width
Height
Availwidth
Availheight
************************/
Alert (screen. availheight + ":" + screen. availwidth );
Alert (history. Length );
VaR onewwin = Window. Open ("about: blank", "newwindow", "Height = 150, width = 300, Top = 10, Left = 10, resizable = yes ");
Onewwin.doc ument. open ();
Onewwin.doc ument. Write ("<HTML> Onewwin.doc ument. Write ("<body> tttttttttttttttttt </body> <HTML> ");
Onewwin.doc ument. Close ();

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.