手机端rem简单配置相关

手机端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

posted @   天天向上518  阅读(95)  评论(0编辑  收藏  举报
编辑推荐:
· SQL Server 2025 AI相关能力初探
· Linux系列:如何用 C#调用 C方法造成内存泄露
· AI与.NET技术实操系列(二):开始使用ML.NET
· 记一次.NET内存居高不下排查解决与启示
· 探究高空视频全景AR技术的实现原理
阅读排行:
· 阿里最新开源QwQ-32B,效果媲美deepseek-r1满血版,部署成本又又又降低了!
· Manus重磅发布:全球首款通用AI代理技术深度解析与实战指南
· 开源Multi-agent AI智能体框架aevatar.ai,欢迎大家贡献代码
· 被坑几百块钱后,我竟然真的恢复了删除的微信聊天记录!
· AI技术革命,工作效率10个最佳AI工具
点击右上角即可分享
微信分享提示