获取网页的高度是在Web开发中常见的需求之一。在JavaScript中,我们可以使用不同的技巧来获取网页的高度。下面是一种常见的方法:
var pageHeight = Math.max(
document.body.scrollHeight,
document.body.offsetHeight,
document.documentElement.clientHeight,
获取网页的高度是在Web开发中常见的需求之一。在JavaScript中,我们可以使用不同的技巧来获取网页的高度。下面是一种常见的方法:
var pageHeight = Math.max(
document.body.scrollHeight,
document.body.offsetHeight,
document.documentElement.clientHeight,