`
endual
  • 浏览: 3510229 次
  • 性别: Icon_minigender_1
  • 来自: 杭州
社区版块
存档分类
最新评论

jquery判断div是否隐藏实例

 
阅读更多
 

jquery判断div是否隐藏实例

分类: jquery 7969人阅读 评论(4) 收藏 举报

<!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=utf-8"/>

<title>绑定函数</title>

<script src="jquery-1.3.2.js"></script>

<script>

$(document).ready(function(){

var temp= $("#test").is(":hidden");//是否隐藏

var temp1= $("#test").is(":visible");//是否可见

alert(temp) ;

alert(temp1) ;

}); </script>

</head>

<body>

<p onclick='test()'>刷新测试</p>

<div id="test" style="display:none"></div>

</body>

</html>

分类: jquery 7969人阅读 评论(4) 收藏 举报

<!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=utf-8"/>

<title>绑定函数</title>

<script src="jquery-1.3.2.js"></script>

<script>

$(document).ready(function(){

var temp= $("#test").is(":hidden");//是否隐藏

var temp1= $("#test").is(":visible");//是否可见

alert(temp) ;

alert(temp1) ;

}); </script>

</head>

<body>

<p onclick='test()'>刷新测试</p>

<div id="test" style="display:none"></div>

</body>

</html>

分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics