🔎Embedding Search
Embed Tellius Search into your app using iFrame and postMessage API—enable direct access, session control, and secure, dynamic analytics integration.
Was this helpful?
Was this helpful?
var telliusFrame ;
document.querySelector("iframe").addEventListener("load", function() {
telliusFrame = document.getElementsByTagName("iframe")[0].contentWindow;
telliusFrame.postMessage('INITIALIZE', "*");
})
function receiveMessage(event) {
if(event.data === 'TELLIUS_INITIALIZED') {
telliusFrame.postMessage({ //if you want to include an actionType
actionType: "required_actionType",
}, "*");
}
}
window.addEventListener("message", receiveMessage, false);