【发布时间】:2016-03-02 08:25:44
【问题描述】:
在我制作的 iPhone 上的网站上,iPhone 似乎无法处理具有动态高度的内容。页脚 div 不会被附加在页脚之前的 div 中的内容向下推。然后页脚和新内容最终相互“重叠”,动态 div 中的内容只是显示为溢出。
有什么办法可以解决这个问题..? (不能在 chromes iPhone 模拟器中重现它)
编辑,这里是附加的代码:
$("#wrapper").empty();
$.each(full_playlist, function(j, current_song){
if(!current_song.now_playing){ //check that the song isnt playing
$("#wrapper").append(List.generateSong(current_song, false, true));
}
});
编辑,页脚和包装的 CSS:
footer{
margin-top:0px !important;
}
#wrapper {
height: 100%;
width: 113%;
overflow: auto;
padding-right: 5vh;
opacity: 1;
}
【问题讨论】:
-
当然,iO 可以处理动态内容。请显示一些代码。
-
使用现在附加的代码编辑帖子。 List.generateSong 仅返回要附加的 html
-
显示页脚的 css 和用于追加的容器。
-
还为页脚和包装添加了 CSS
标签: javascript jquery iphone dynamic append