我有一个这样定义的部分:
<footer>
<section id="content">
<section id="footer-links" class="center">
<a href="index.php" class="float-left">Home</a>
<a href="about.html" class="float-left">About</a>
<a href="contact.html" class="float-left">Contact</a>
<a href="terms.html" class="float-left">Terms and Conditions</a>
</section>
</section>
</footer>
我已经应用了以下 CSS:
页脚
background-color:
rgb(53, 53, 181);
color:
rgb(255, 255, 255);
display: block;
font-size: 16px;
height: 100px;
width: 1424px;
部分(#内容)
background-color:
rgba(0, 0, 0, 0);
color:
rgb(255, 255, 255);
display: block;
font-size: 16px;
height: 19px;
margin-bottom: 0px;
margin-left: 312px;
margin-right: 312px;
margin-top: 0px;
position: relative;
width: 800px;
部分(#footer-links)
background-color:
rgba(0, 0, 0, 0);
color:
rgb(255, 255, 255);
display: inline-block;
font-size: 16px;
height: 19px;
margin-left: 0px;
margin-right: 0px;
width: 332px;
一个
background-color:
rgba(0, 0, 0, 0);
border-bottom-color:
rgb(222, 222, 222);
border-bottom-style: dotted;
border-bottom-width: 1px;
color:
rgb(222, 222, 222);
cursor: auto;
display: block;
float: left;
font-size: 16px;
height: 18px;
margin-right: 16px;
text-decoration: none;
width: 39px;
但是,如您所见,它左对齐section
. 希望大家能帮忙!