domain property (event)
Returns the hostname of the server that served the document that caused the onmessage event.
Note: The support for the domain and domain properties has been removed in Opera 10. In Firefox, Google Chrome, Safari, Internet Explorer from version 8 and Opera from version 10, use the origin property instead.An onmessage event occurs when the postMessage method sends a message to the current window. For details, see the pages for the postMessage method and the onmessage event.
You can find the related objects in the Supported by objects section below.
This property is read-only.
String that retrieves the domain.
Default: this property has no default value.
Example HTML code 1:
This example illustrates the use of the domain property:
Did you find this example helpful?
User Contributed Comments