<script> //取得iframe的元素 function getIframe(id) { return document.getElementById(id).contentWindow.document; } //父窗口访问子窗口元素 function frameDiv() { for (var i = 1; i < 11; i++) { var iframe = 'Iframe' + i.toString(); var url = '#Hidden' + i.toString(); document.getElementById(iframe).contentWindow.document.getElementById('imageThumb').src = $(url).val(); } } </script> </head>