This page is In Progress

Notice: The WebPlatform project, supported by various stewards between 2012 and 2015, has been discontinued. This site is now available on github.

data

Summary

Gets the content of the message.

Property of dom/MessageEventdom/MessageEvent

Syntax

Note: This property is read-only.

var data = event.html/elements/data;

Return Value

Returns an object of type anyany

The content of the message.

Notes

This property contains the value passed to postMessage. Before trusting the data, check the URL property of the message request to determine its source.

Attributions