请老师帮忙看看我的代码。想知道图片和图片之间的空白怎么去除,底部的空白怎么消去。
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title></title>
<style type="text/css">
/*此处写代码*/
*{margin:0;
padding:0;
}
body{height: 2900px;
}
.tb{background:black;
width:100%;
height:100px;
position:absolute;
top: 0;
position: fixed;
}
.logo{
background:url(http://img1.sycdn.imooc.com/climg//58c0d2d900016ce303000100.png);
width:300px;
height:100px;
float:left;
}
.dht{
width:100px;
height: auto;
color: white;
float: right;
font-size: 20px;
line-height: 100px;
margin-left:30px;
text-align: center;
cursor: pointer;
}
.dht:nth-child(4){margin-left: 40px;}
.wb{
background-color: black;
width: 100%;
height: 100px;
bottom: 0;
position: fixed;
}
.ljqy{float: left;
margin: 0 10px}
.ljq{color: white;
line-height: 100px;
float: left;
margin: 0px 50px;
text-align: center;
width: 100px;
}
.tp1{background: url(http://img1.sycdn.imooc.com/climg//58c0eda50001e12416000480.jpg) top center no-repeat;
width: 100%;
height:500px;
margin-top: 100px;
}
.tp2{background: url(http://img1.sycdn.imooc.com/climg//58c0edb80001c9f216000480.jpg) top center no-repeat;
width: 100%;height:500px;
}
.tp3{background: url(http://img1.sycdn.imooc.com/climg//58c0edc9000100d516000480.jpg) top center no-repeat;
width: 100%;height:500px;
}
</style>
</head>
<body>
<!-- 此处写代码 -->
<div class="tb">
<div class="logo"></div>
<div class="dht">手记</div>
<div class="dht">猿问</div>
<div class="dht">实战</div>
<div class="dht">职业路径</div>
<div class="dht">课程</div>
</div>
<div class="tp1"></div>
<div class="tp2"></div>
<div class="tp3"></div>
<div class="wb">
<div class="ljqy">
<div class="ljq">网站首页</div>
<div class="ljq">企业合作</div>
<div class="ljq">人才招聘</div>
<div class="ljq">联系我们</div>
<div class="ljq">常见问题</div>
<div class="ljq">友情链接</div>
</div>
</div>
</body>
</html>13
收起
正在回答 回答被采纳积分+1
2回答
前端小白入门系列课程
- 参与学习 人
- 提交作业 11218 份
- 解答问题 36712 个
从一个不会编程的小白到一个老司机是需要过程的,首先得入门,学习基础知识,然后才能进阶,最后再到精通,本专题是你走进前端世界的不二选择!
了解课程

恭喜解决一个难题,获得1积分~
来为老师/同学的回答评分吧
0 星