<script type="text/javascript"> ? function openWindon(){ if(confirm("確定打開新窗口嗎?")){ var url = prompt("請(qǐng)輸入一個(gè)網(wǎng)址","http://idcbgp.cn/"); window.open( url,"_blank","toolbar=no, menubar=no, scrollbars=yes, ?width=400, height=400"); } }</script> </head><body><input type="button" value="新窗口打開網(wǎng)站" onclick="openWindon()" />
6 回答

請(qǐng)叫我攻城喵
TA貢獻(xiàn)5條經(jīng)驗(yàn) 獲得超21個(gè)贊
_self是在當(dāng)前頁(yè)打開,原網(wǎng)頁(yè)不在
_blank是在新標(biāo)簽頁(yè)打開,原網(wǎng)頁(yè)還在