0
彈出--mainPage.php ----popUpWindow不會在iframe
<div>
<iframe>pageA.php</iframe>
</div>
<div>
<iframe>pageB.php</iframe>
</div>
主要頁面包括兩個I幀,其鏈接到pageA.php和pageB.php seperatly。
在PageA.php上,有一個鏈接點擊顯示popUpWindow.php。 (請參閱popUpwindow示例:http://www.javascript-coder.com/files/window-popup/javascript-window-open-example1.html)。
在我的情況下,popUpWindow.php不彈出,單擊鏈接後,pageA.php被替換爲popUpWindow.php。以下是我的代碼,任何人都可以幫助我嗎?提前致謝!
--pageA.php -----
<script type="text/javascript">
// Popup window code
function newPopup(url) {
popupWindow = window.open(
url,'popUpWindow','height=700,width=700,left=10,top=10,resizable=yes,scrollbars=yes,toolbar=yes,menubar=no,location=no,directories=no,status=yes')
}
</script>
<a href="popUpWindow.php">Link</a>
您需要設置錨點目標。 – Filip