Created
February 1, 2020 15:58
-
-
Save garethredfern/f919d371c3adc165aba8125a11b6ee83 to your computer and use it in GitHub Desktop.
Send a message from child content through an iframe.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// https://developer.mozilla.org/en-US/docs/Web/API/Window/postMessage | |
H5P.externalDispatcher.on("xAPI", function(event) { | |
window.parent.postMessage(event.data.statement, "*"); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment