运用“浮动”的导航条。
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Document</title>
<style type="text/css">
*{
margin: 0;
padding: 0;
}
.nav{
list-style: none;
background: rgb(243, 235, 235);
width: 694px;
border:1px solid gold;
margin: 50px auto;
overflow:hidden;
zoom: 1;
}
.nav li{
float: left;
width:98px;
border-left: 1px gold solid;
}
.nav a{
display:block;
text-align: center;
padding: 17px 0;
text-decoration: none;
font-weight: bold;
color: pink;
}
ul > li:first-child{
border-left: none;
}
</style>
</head>
<body>
<ul class="nav">
<li><a href="#">首页</a></li>
<li><a href="#">公司简介</a></li>
<li><a href="#">解决方案</a></li>
<li><a href="#">公司新闻</a></li>
<li><a href="#">行业动态</a></li>
<li><a href="#">招贤纳才</a></li>
<li><a href="#">联系我们</a></li>
</ul>
</body>
</html>
QQ截图20180329212246.png