You are here: irt.org | FAQ | JavaScript | Window | Q1341 [ previous next ]
Try:
<body>
<script language="JavaScript"><!--
var width = 640, height = 480; // defaults
if (document.layers) {
width = window.innerWidth;
height = window.innerHeight;
}
else if (document.all) {
width = document.body.clientWidth;
height = document.body.clientHeight;
}
//--></script>
....
</body>