fixed bug

  • ios下fixed元素容易定位出错,软键盘弹出时,影响fixed元素定位
  • android下fixed表现要比iOS更好,软键盘弹出时,不会影响fixed元素定位
  • ios4下不支持position:fixed

解决方案

  • 可用isroll.js,暂无完美方案

参考

移动端web页面使用position:fixed问题总结》https://github.com/maxzhang/maxzhang.github.com/issues/2

使用iScroll.js解决ios4下不支持position:fixed的问题》http://www.cnblogs.com/PeunZhang/archive/2013/06/14/3117589.html

原文地址:https://www.cnblogs.com/webgg/p/5341837.html