父頁面通過window.open打開的子頁面father.html<input type="" name="main" id="mmm" value="123" /><script type="text/javascript">
$('#Btn').on('click',function(){ window.open('son.html');
});</script>son.html <script type="text/javascript">
alert(window.opener.document.getElementById('mmm').value); </script>控制臺Uncaught TypeError: Cannot read property 'value' of null at son.html:21
window.open 傳值為空?
陪伴而非守候
2018-09-11 09:14:31