有兩個檔案a.html, b.html
要求是,點擊a檔案,打開頁面b,并且b.html自動放大占滿雙螢屏。
單純的點擊a.html, 可以實作效果。
但是如果把兩個檔案放到tomcat下面, 通過網址去啟動a.html(http://192.168.2.24:8080/test/a.html),
這時候b.html的大小只有一螢屏左右的大小。
有什么方法可以解決么?
瀏覽器:IE11
a檔案的代碼:
var bsh = window.screen.height;
var bsw = window.screen.width;
// alert("bsh:"+bsh+"bsw:"+bsw);
option = "fullscreen=no,toolbar=0,menubar=0,resizable=0,left=0,top=0,width="+bsw*2+",height="+bsh
window.open("b.html","main",option);
//window close処理用
ow = window.open("","_top");
ow.opener = window;
uj5u.com熱心網友回復:
在可以的情況下 和不行的情況下都 alert一下 bsh bsw的值看看有區別嗎?
uj5u.com熱心網友回復:
厲害啊厲害啊轉載請註明出處,本文鏈接:https://www.uj5u.com/qianduan/28837.html
標籤:JavaScript
