我正在尝试更改网站的页脚颜色。我已经尝试了一切,但似乎没有用!
以下是我的CSS链接:http://pp.atoanavida.com.br/style2.css
这是页面:http://pp.atoanavida.com.br
感谢!!!!
答案 0 :(得分:2)
你的代码中有一些无效的CSS。
在#footer
下,将background: { #77aadd !important;}
更改为:
background: #77aadd !important;
或background-color: #77aadd !important;
修改强>
在您的HTML中,在关闭<div style="clear:both;"></div>
之前(关闭<div id="footer">
之后)立即添加<div id="footer-content">
。
答案 1 :(得分:1)
替换
#footer {
clear: both;
background: { #77aadd !important;}
margin: 0; padding: 0;
font: normal .95em/1.5em 'Tahoma', Trebuchet MS, Sans-serif;
width:100%;
}
与
#footer {
clear: both;
background-color: #77aadd !important;
margin: 0; padding: 0;
font: normal .95em/1.5em 'Tahoma', Trebuchet MS, Sans-serif;
width:100%;
}
#footer-content
语法也有同样的问题,替换
#footer-content {
border-top: 0px solid #EAEAEA;
margin: 0 auto;
padding-left: 15px auto;
background: { #77aadd !important;}
width:100%;
}
与
#footer-content {
border-top: 0px solid #EAEAEA;
margin: 0 auto;
padding-left: 15px;
background-color: #77aadd !important;
width:100%;
}
答案 2 :(得分:0)
您需要清除#footer-content
内的浮动元素。
一种简单的方法是将overflow: hidden
添加到#footer-content
的CSS中。
我建议您阅读类似这样的文章,了解详情:http://css-tricks.com/all-about-floats/