Private archive copy · Unofficial site · Content copyright belongs to Runoob Tutorial and the original authors · View Original

HTML DOM domain property

HTML domain property

Document Object Reference Document Object


Definition and Usage

The domain property returns the server domain from which the current document was downloaded:

Syntax

document.domain


Browser support

Internet ExplorerFirefoxOperaGoogle ChromeSafari

All major browsers support the domain property


Example

Example

Return the server domain name from which the current document was downloaded:

The domain name that loaded this file:

Try it »


Document Object Reference Document Object