<!DOCTYPE html>
<html>
<head>
<title>请调整浏览器窗口</title>
<meta charset="UTF-8">
</head>
<body>
<h2 align="center">请调整浏览器窗口大小</h2>
<hr>
<form action="#" method="get" name="form1" id="form1">
浏览器窗口的实际高度: <input id="height" type="text" name="availHeight" size="4"><br>
浏览器窗口的实际宽度: <input id="width" type="text" name="availWidth" size="4"><br>
</form>
<script>
document.getElementById('height').value = window.outerHeight + "px";
document.getElementById('width').value = window.outerWidth + "px";
window.onresize=function(){
document.getElementById('height').value = window.outerHeight + "px";
document.getElementById('width').value = window.outerWidth + "px";
};
</script>
</body>
</html>