hongjiumu

javascript获取的层(div)高度

2012-09-12 10:21  hongjiumu  阅读(349)  评论(0编辑  收藏  举报
<!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>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>Untitled Document</title>
<script type="text/javascript">
function aa(){
alert(document.getElementById("userBlog").offsetHeight+"px");
}
</script>
</head>
<body onload="aa();">
<div id="userBlog">Content for New Div<br /><br /> Tag Goes Here</div>
</body>
</html>

分类:

技术点:

相关文章:

  • 2021-11-18
  • 2021-08-28
  • 2021-06-13
  • 2022-01-17
  • 2021-12-20
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-12-25
  • 2021-11-30
  • 2021-12-25
  • 2021-12-25
  • 2021-12-23
  • 2021-12-26
  • 2022-12-23
相关资源
相似解决方案