首页 > 移动平台 > 详细

手机端rem简单配置相关

时间:2021-02-09 22:16:47      阅读:37      评论:0      收藏:0      [点我收藏+]

手机端rem简单配置相关

 1 <!DOCTYPE html>
 2 <html xmlns="http://www.w3.org/1999/xhtml">
 3 <head runat="server">
 4     <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
 5     <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
 6     <title></title>
 7     <link href="/Content/css/bootstrap.min.css" rel="stylesheet" />
 8     <style type="text/css">
 9         html {
10             font-size: 625%;
11         }
12 
13         body {
14             font-size: .16rem; //相当于16px的含义
15             background-color:#ffffff;
16         }
17 
18         div, p, h1, h2, h3, h4, ul, li, dl, dd {
19             margin: 0px;
20             padding: 0px;
21         }
22 
23         img.imgshow {
24             max-width: 100%;
25             display: block;
26         }
27 
28         .content {
29             width: 100%;
30             background-color: #f00;
31             height: auto;
32         }
33         .product_info .price {
34                 float: left;
35                 color: #666;
36                 letter-spacing: 0.02rem;
37                 font-weight: normal;
38                 font-size: 0.14rem;
39         }
40         .content-list dl {
41             background-color: #ffffff;
42             margin-bottom: 0.08rem;
43         }
44     </style>
45 </head>

已经在微信公众号H5中测试OK

手机端rem简单配置相关

原文:https://www.cnblogs.com/Fengge518/p/14393641.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!