Javascript Reference
Categories: document

javascript document domain

@June 20, 2009, 12:50 p.m.
domain Firefox/Netscape/NN 3 IE 4 Chrome/Safari/DOM 1



Provides the hostname of the server that served up the document. If documents from different servers on the same domain must exchange content with each other, the domain properties of both documents must be set to the same domain to avoid security restrictions. Normally, if the hosts don't match, browser security disallows access to the other document's form data. This property allows, for example, a page from the www server to communicate with a page served up by a secure server.

document.domain = "";

String of the domain name that two documents have in common (exclusive of the server name).



Powered by Linode.