适配移动

小米适配js ///rem设置大小

  <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=0">
    <!-- meta(name="full-screen", content="yes")-->
    <meta name="imagemode" content="force">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <meta name="format-detection" content="telephone=no">


<script> !function (n) { var e = n.document, t = e.documentElement, i = 640, d = i / 100, o = "orientationchange" in n ? "orientationchange" : "resize", a = function () { var n = t.clientWidth || 320; n > 640 && (n = 640), t.style.fontSize = n / d + "px" }; e.addEventListener && (n.addEventListener(o, a, !1), e.addEventListener("DOMContentLoaded", a, !1)) }(window); </script>

 

posted @ 2015-12-29 18:55  hupan508  阅读(250)  评论(0编辑  收藏  举报