<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title></title>
<script type="text/javascript" src="js/jquery-3.3.1.min.js"></script>
<script>
$(function(){
$('#flip').click(function(){
$("#panel").slideToggle('slow');
});
});
</script>
<style>
#panel,#flip{
padding: 5px;
text-align: center;
background-color: deepskyblue;
border: 1px solid red;
}
#panel{
height: 300px;
display: none;
}
</style>
</head>
<body>
<div id="flip">点我切换隐藏区域</div>
<div id="panel">hello world!</div>
</body>
</html>
python前端基础--jquery动画02
最新推荐文章于 2020-02-16 16:25:16 发布