SOURCE

console 命令行工具 X clear

                    
>
console
var script = document.creatElement('script');
script.src = 'http://xxx.xxx.xxx?callback=handleFun'
document.body.appendChild(script);

handleFun (data) {
  // data 就是响应的数据
}

http://www.ex.com/a.html
  <iframe id="ifr" src="http://ex.com/b.html" onload="test()"></iframe>
  
	document.domain = 'ex.com'
  var ifr = document.getElementById('ifr');
  test () {
    var obj = ifr.contentWindow; // 就可以获取b页面的一些属性了
  }

http://ex.com/b.html
	document.domain = 'ex.com'
  
  

http://www.a.com/a.html
	<iframe id="ifr" src="http://ex.com/b.html" style="dispaly:none;" onload="test()"></iframe>
  
  var ifr = document.getElementById('ifr');
  test () {
    var data = ifr.contentWindow.name;
    ifr.src = '##';
  }
  
  
http://www.b.com/b.html
	window.name ="我给a的我这边的数据"
<body></body>