lsc 2 years ago
parent
commit
c347a7f6ba
1 changed files with 11 additions and 0 deletions
  1. 11 0
      index.html

+ 11 - 0
index.html

@@ -45,6 +45,17 @@
     <script type="text/javascript">
         document.domain = document.domain.split(".").slice(-2).join(".");
     </script>
+    <meta name="viewport" id="viewportMeta">
+    <script>
+        var initViewport = function (height) {
+            var metaEl = document.querySelector("#viewportMeta");
+            var content = "height=device-height" + ",width=device-width,initial-scale=1.0,user-scalable=no";
+            metaEl.setAttribute('name', 'viewport');
+            metaEl.setAttribute('content', content);
+        }
+        var realHeight = window.innerWidth > window.innerHeight ? window.innerWidth : window.innerHeight
+        initViewport(realHeight);
+    </script>
 </head>
 
 <body scroll="no" class="U_MD_D_NotText Scrollbar" style="overflow: hidden;">