js--window.postMessage
父页面想子页面发送消息:
var iframe=document.getElementById('centerFormIframe_iframe').contentWindow; iframe.postMessage('full','*');
子页面向父页面发送消息:
window.parent.postMessage('full','*');
监听:
window.addEventListener('message',function(e){ if(e.data=='exit'){} })