码迷,mamicode.com
首页 > Web开发 > 详细

html5 css折叠导航栏

时间:2018-10-08 11:25:10      阅读:507      评论:0      收藏:0      [点我收藏+]

标签:charset   htm   pad   ack   type   idt   ora   tle   20px   

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>旋转菜单</title>
    <link rel="stylesheet" href="style8.css" type="text/css">
</head>
<body>
<div class="se">
<h3><a href="">IT</a></h3>
<div><img src="imges/it.jpg" ></div>    
</div>

<div class="se">
<h3><a href="">创投</a></h3>
<div><img src="imges/kk.jpg" ></div>    
</div>

<div class="se">
<h3><a href="">探索</a></h3>
<div><img src="imges/dd.jpg" ></div>    
</div>
</body>
</html>

 

img{
    width: 500px;
    height: 345px;
}
*{
    margin: 0;
    padding: 0;

}
h3+div{
    height: 0px;
    overflow: hidden;
    transform: all 1s ease;
}
a{
    text-decoration: none;
}
.se{
    width: 300px;
    background: rgba(180,60,30,0.3);
    margin-top: 5px;
    margin-left: 20px;
    float: left;
}
h3{
    background: rgba(180,80,30,0.8);
    padding: 5px 25px;
    border-radius: 20px;
}
.se:hover h3+div{
height: 345px;
overflow: auto;
}

html5 css折叠导航栏

标签:charset   htm   pad   ack   type   idt   ora   tle   20px   

原文地址:https://www.cnblogs.com/houweidong/p/9752973.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!