js加载事使浏览器自动最大化
function resizeWindow() {
if (window.screen) {//判断浏览器是否支持window.screen判断浏览器是否支持screen
var myw = screen.availWidth; //定义一个myw,接受到当前全屏的宽
var myh = screen.availHeight; //定义一个myw,接受到当前全屏的高
window.moveTo(0, 0); //把window放在左上脚
window.resizeTo(myw, myh); //把当前窗体的长宽跳转为myw和myh
}
}
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title></title>
</head>
<body onload="javascript:resizeWindow();">
</body>