初二上册期中数学试卷:ASP:如何获得网页body的高度?
来源:百度文库 编辑:杭州交通信息网 时间:2024/05/29 10:25:24
<script>
alert(document.body.height);
</script>
这么写不行,那该怎么写?
alert(document.body.height);
</script>
这么写不行,那该怎么写?
这样改
<script>
alert(document.body.clientHeight);
</script>
也就是说将height改为clientHeight