我想在AJAX调用,以检查是否响应变量的长度是更大然后1 如果这是真的,我需要这种风格添加到我的页脚:使用jQuery添加CSS样式没有任何影响
success: function(response) {
for (var i = 0, len = response.results.length; i < len; i++)
{
if(response.results.length>1)
{
$("#footer").css("position:relative");
}
}....
}
这是我的义样式在我的CSS文件:
#footer
{
z-index:11;
bottom:0;
position: fixed;
float: left;
width:100%;
height:30px;
background-color:black;
}
我做了一些调试和一切工作,因为它应该是工作,但我的脚部构件仍具有position:fixed
我在这里做错了什么?
你的回答是正确的..谢谢 – 2013-03-14 15:00:25