立即註冊 登入
PIGOO 痞酷網 返回首頁

fakedeireas的個人空間 https://bbs.pigoo.com/?62921 [收藏] [複製] [分享] [RSS]

日誌

IE, Chrome 通用 showModalDialog 語法

已有 5379 次閱讀2014-4-3 05:01 PM |個人分類:系統記事本| showModalDialog, 語法

母視窗
//SetName 接收欄位
var returnValue = window.showModalDialog(CallUrl,false,"dialogWidth:800px;dialogHeight:500px;status:0;");
    
//for IE
if (returnValue != undefined) {
document.all[SetName].value = returnValue;
} else {
//for chrome
if (window.returnValue != undefined) {
document.all[SetName].value = window.returnValue;
}
}

子視窗:
if (window.opener != undefined) {
//for chrome
window.opener.returnValue = returnValue;
} else {
//for IE
window.returnValue = returnValue;
}


路過

雞蛋

鮮花

握手

雷人

全部作者的其他最新日誌

評論 (0 個評論)

facelist

您需要登入後纔可以評論 登入 | 立即註冊

手機版|禁閉室|連繫我們|痞酷網電子技術論壇

GMT+8, 2026-9-5 04:26 PM , Processed in 0.013608 second(s), 7 queries , Redis On.

Powered by Discuz! X5.0 Licensed

© 2001-2026 Discuz! Team.

返回頂部