You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've found the way to send messagefrom iframe to parent, through using $sf.ext.message and posMessageCallback, but I cannot find a way to send a message from parent window to iframe.
I find one method in host.js, as you can see the below.
/** * Send a message to a child iframe. * * @name $sf.lib.dom.msghost.send * @public * @static * @function * @param {string} tgtID The HTML id attribute of the iframe element for which to send a message * @param {string} data The string of data to send to the given iframe * @returns {boolean} Whether or not message was send succesfully (note that this does not mean message was handled / recevied, only that sending was ok). * */functionsend_msg_to_child_iframe(tgtID,data)
It looks like what I intended, but I still don't know how iframe gets message from parent.
(I'm concerning the alternative way using #9 if there's no way.)
Any help will be great.
Thx.
The text was updated successfully, but these errors were encountered:
you can't. . that method is not really intended for your own use, it's used from SafeFrames internally. There is purposefully no way to allow you to receive a postmessage in a safeframe right now. . .that's an on going discussion that has to be addressed via a rewrite of the message bus that I haven't gotten around too. . .
I've found the way to send message
from iframe to parent
, through using$sf.ext.message
andposMessageCallback
, but I cannot find a way to send a messagefrom parent window to iframe
.I find one method in
host.js
, as you can see the below.Also, method of use (that I'm gussing)
It looks like what I intended, but I still don't know how iframe gets message from parent.
(I'm concerning the alternative way using #9 if there's no way.)
Any help will be great.
Thx.
The text was updated successfully, but these errors were encountered: