12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758 |
- <!DOCTYPE html>
- <html>
- <head>
- <meta charset="UTF-8">
- <meta content="yes" name="apple-mobile-web-app-capable">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0,minimum-scale=1.0,user-scalable=0" />
- <title>常见问题</title>
- <link rel="stylesheet" type="text/css" href="../common/reset.css"/>
- <style type="text/css">
- body{background: #FFFFFF;min-height:100vh ;}
- .Q,.A{padding-right: 0.1rem;}
- .Q{padding-top: 0.2rem;display: flex;border-top: 0.01rem dashed #ccc;}
- .Q:nth-of-type(1){padding-top: 0.2rem;border-top: none;}
- .icon{margin-left: 0.2rem;margin-right: 0.15rem;width: 0.18rem;height: 0.18rem;}
- .Q h3{color: #333333;font-size: 0.15rem;line-height: 0.18rem;font-weight: bold;flex: 1;}
- .A{display: flex;margin-top: 0.2rem;}
- .A .icon{margin-top: 0.06rem;}
- .A .con{font-size: 0.15rem;color: #626262;line-height: 0.25rem;flex: 1;padding-bottom: 0.2rem;}
- .A .con img{max-width: calc(100% - 0.1rem);margin: 0.1rem 0;}
- .A .con p{margin: 0.1rem 0;}
- .A .con p:nth-of-type(1){margin: 0;}
- </style>
- </head>
- <body>
- <div id="content"></div>
- </body>
- </html>
- <script type="text/javascript" src="problem.js?v=1"></script>
- <script type="text/javascript">
- document.documentElement.style.fontSize = 100 * (document.documentElement.clientWidth/375) + "px";
- window.onresize = function(){
- document.documentElement.style.fontSize = 100 * (document.documentElement.clientWidth/375) + "px";
- }
- function parseQueryString(url) {
- var urlObj = {};
- var reg = /([^?=&]+)=([^?=&]+)/g;
- url.replace(reg, function($0, $1, $2) {
- urlObj[$1] = decodeURIComponent($2);
- })
- return urlObj;
- }
- var qs = parseQueryString(window.location.href);
- var id = 0;
- var Content = document.getElementById("content");
- var html = '';
- if(qs.id){
- id = qs.id
- }
-
- problem.forEach(function (items, index) {
- if(items.id == id){
- items.content.forEach(function (item, index) {
- html += '<div class="Q"><img class="icon" src="img/Q.png" /><h3>' + item.title + '</h3></div><div class="A"><img class="icon" src="img/A.png" /><div class="con">' + item.con + '</div></div><div class="bottom"></div>'
- })
- }
- })
- Content.innerHTML = html;
- </script>
|