.btn{display: block;width:100%;padding:10px;border:none;cursor: pointer;outline: none;}
.btn-primary{ font-size: 18px;padding: 15px;border-radius: 4px;color: white;background-color: #ff8a00;-moz-box-shadow: 0 3px 0 #e97005; -webkit-box-shadow: 0 3px 0 #e97005; box-shadow: 0 3px 0 #e97005;}
.pd-15{padding-left:25px;padding-right:25px;}
.orange{color:#ff6022;}
.bold{font-weight: bold;} .share-wrapper{ background:url(../images/share_bg.png);background-size:cover;width:100%;} .main-content{padding-top: 30px}
.title{margin-top: 10px;font-size: 22px;font-weight: bolder;color:#027794;}
.text{color:#027794;font-size:16px;margin-bottom: 10px;} .hint{position:fixed;top:0;left:0;z-index:3000;display:none;}
.hint .img{display: block;width:100%;height:auto;}
#global-mask{position: fixed;z-index: 2000;left: 0;top:0;width:100%;height: 100%;background: #000;opacity:0.7;display: none;} @media (min-width: 400px){
.btn-primary{margin-top: 20px;}
}
@media (max-width: 320px){
.main-content{padding-top: 20px}
.title{font-size:20px;}
.text{padding: 0 40px;}
.pd-15{padding-top: 0;}
} #weixin-tip{display:none;position:fixed;left:0;top:0;background:rgba(0,0,0,0.8);filter:alpha(opacity=80);width:100%;height:100%;z-index:100;}
#weixin-tip p{text-align:center;margin-top:10%;padding:0 5%;position:relative;}
#weixin-tip .close{color:#fff;padding:5px;font:bold 20px/24px simsun;text-shadow:0 1px 0 #ddd;position:absolute;top:0;left:5%;}

<link href="CSS/Untitled-3.css" rel="stylesheet" />
    <link href="CSS/Untitled-4.css" rel="stylesheet" />

/* ==========================================================================
#CssReset
========================================================================== */ html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed,
figure, figcaption, footer, header, hgroup,
menu, nav, output, ruby, section, summary,
time, mark, audio, video {
margin: 0;
padding: 0;
border: 0;
font-size: 100%;
font: inherit;
vertical-align: baseline;
} /* HTML5 display-role reset for older browsers */ article,
aside,
details,
figcaption,
figure,
footer,
header,
hgroup,
menu,
nav,
section {
display: block;
} body {
line-height: 1;
} ol,
ul {
list-style: none;
} a img{
border:none;
}
em,i{
font-style:normal;
} blockquote,
q {
quotes: none;
} blockquote:before,
blockquote:after,
q:before,
q:after {
content: "";
content: none;
} table {
border-collapse: collapse;
border-spacing: 0;
} a{
text-decoration:none;
cursor:pointer;
font-style:normal;
outline:none;
color:inherit;
}
a:link,a:visited,a:hover,a:active{
text-decoration:none;
color:inherit;
}
a:focus{
outline:0;
} input{
vertical-align:middle;
border:0 none;
-webkit-appearance: none;
}
input:focus{
text-decoration:none;
outline:none;
} img {
border: 0;
/* 1 */
-ms-interpolation-mode: bicubic;
/* 2 */
max-width: 100%;
height:auto;
} /* ==========================================================================
#Grid
========================================================================== */
*{
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
} .sec{
width:100%;
background:white;
} .row{
width:100%;
padding:15px 0;
overflow: hidden;
} .row:after, .clearfix:after{
clear:both;
content:'';
display: block;
height:0;
overflow:hidden;
} .span1,.span2,.span3,.span4,.span5,.span6,.span7,.span8,.span9,.span10,.span11,.span12{
float:left;
} .span12{
width:100%
}
.span11{
width:91.66666667%
}
.span10{
width:83.33333333%
}
.span9{
width:75%
}
.span8{
width:66.66666667%
}
.span7{
width:58.33333333%
}
.span6{
width:50%
}
.span5{
width:41.66666667%
}
.span4{
width:33.33333333%
}
.span3{
width:25%
}
.span2{
width:16.66666667%
}
.span1{
width:8.33333333%
} .col-offset-1{
margin-left:4.33333333%
} .pull-left{
float: left;
} .pull-right{
float: right;
} .text-center{
text-align: center;
} .text-right{
text-align: right;
} .text-left{
text-align: left;
} .font12{
font-size:1.2rem;
} .font14{
font-size:1.4rem;
} .btn{
width:100%;
display: block;
} .hide{
display: none;
} .block{
display: block;
} select{
-webkit-appearance: none !important;
background: #fafafa url('../images/arrow.png') no-repeat 0 0;
background-position-x: 96%;
background-position-y: center;
border: 1px solid #ccc;
padding: 0.5rem;
font-size: 0.875rem;
-webkit-border-radius: 0;
border-radius: 0;
position: relative;
width:98%;
outline: none;
} .wid50{
width:50%;
} /* ==========================================================================
#CustomCSS
========================================================================== */ body {
background:#daf3f9;
font-family: "Microsoft YaHei", "Helvetica Neue", Helvetica, Arial, sans-serif;
font-size:14px;
color: #434343;
overflow-x:hidden;
} /* ==========================================================================
#Browers
========================================================================== */
a, div, header, span, input {
-webkit-tap-highlight-color: rgba(255,255,255,0);
}

  html

<!DOCTYPE html>
<html lang="cn">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0" />
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1,requiresActiveX=true">
<title>天下先APP下载</title>
<link href="CSS/Untitled-3.css" rel="stylesheet" />
<link href="CSS/Untitled-4.css" rel="stylesheet" />
</head> <body>
<div class=" share-wrapper full-screen">
<div class="main-content text-center">
<div class="share-header">
<a href="http://apk.ymt.com/link?channel=FR_OP_PCTOP"><img src="data:images/ic_launcher.png" alt="天下先"></a>
</div>
<div class="row">
<h1 class="title">天下先APP下载</h1>
</div>
<div class="row">
<p class="text"></p>
</div>
<div class="row pd-15">
<a id="J_weixin" class="android-btn" href="http://txxnby.xicp.cn:8091/TianXiaXian_3.4.apk"><button id="" class="btn btn-primary">免费下载天下先APP</button></a>
<div id="weixin-tip"><p><img src="data:images/live_weixin.png" alt="微信扫描打开APP下载链接提示代码优化" alt="微信打开"/><span id="close" title="关闭" class="close">×</span></p></div> </div>
</div>
</div>
<script>
function handleFullScreenDiv() {
var x = document.documentElement.clientHeight;
var y = document.documentElement.clientWidth;
var fullscreen = document.querySelector('.full-screen') || document.getElementByClassName('full-screen');
var img = document.getElementById('img'); fullscreen.style.minHeight = x + "px";
img.style.minWidth = y + "px"; } window.onresize = function() {
handleFullScreenDiv();
} function getQueryString(name) {
var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
var r = window.location.search.substr(1).match(reg);
if (r != null) return unescape(r[2]); return null;
}
var review = getQueryString("review");
if('yes' == review) {
window.location.href = "ymtpage://com.ymt360.app.mass";
} // var is_weixin = (function() { //判断微信UA
// var ua = navigator.userAgent.toLowerCase();
// if (ua.match(/MicroMessenger/i) == "micromessenger") {
// return true;
// } else {
// return false;
// }
// })(); var is_weixin = (function(){return navigator.userAgent.toLowerCase().indexOf('micromessenger') !== -1})();
window.onload = function() {
var winHeight = typeof window.innerHeight != 'undefined' ? window.innerHeight : document.documentElement.clientHeight; //兼容IOS,不需要的可以去掉
var btn = document.getElementById('J_weixin');
var tip = document.getElementById('weixin-tip');
var close = document.getElementById('close');
if (is_weixin) {
btn.onclick = function(e) {
tip.style.height = winHeight + 'px'; //兼容IOS弹窗整屏
tip.style.display = 'block';
return false;
}
close.onclick = function() {
tip.style.display = 'none';
}
}
}
</script>
</body> </html>

  

apk下载解决微信扫一扫问题的更多相关文章

  1. 微信浏览器无法跳转到apk下载链接 微信屏蔽了我的APP下载链接如何处理

    由于微信的限制,应用文件在内置浏览器中下载全部被屏蔽掉,造成很多人用微信扫描二维码下载时,界面显示一片空白,容易误导以为在下载呢 <!DOCTYPE html><html>&l ...

  2. 调用微信的扫一扫功能详解说明---(java 排坑版)

    最近碰到了这么一个需求,说是在前端页面调用手机本地的相机,扫描二维码这么一个需求,对于我一个后端来说, 这实在是难,难于上青天,但是决不能说一个不字.我说可以使用微信的扫码工具吗,这样可以方便一点,. ...

  3. 微信公众平台:扫一扫demo

    ylbtech-微信公众平台:扫一扫demo 1.返回顶部 1.Web.config <appSettings> <add key="appid" value=& ...

  4. C#开发微信门户及应用(15)-微信菜单增加扫一扫、发图片、发地理位置功能

    前面介绍了很多篇关于使用C#开发微信门户及应用的文章,基本上把当时微信能做的接口都封装差不多了,微信框架也积累了不少模块和用户,最近发现微信公众平台增加了不少内容,特别是在自定义菜单里面增加了扫一扫. ...

  5. ASP.NET MVC做的微信WEBAPP中调用微信JSSDK扫一扫

    今天做一个项目,是在微信上用的,微信WEB APP,里面用到了调用手机摄像头扫一扫二维码的功能,记得以前某个项目里写有的,但是找不到之前那个项目源码了,想复制粘贴也复制不了了,只好对着微信的那个开发文 ...

  6. Mockplus微信小程序上线!扫一扫轻松查看原型!

    Mockplus团队发布了Mockplus微信小程序. 从现在起,你无需下载Mockplus移动端,用微信扫一扫二维码,即可在微信中打开并查看原型.Mockplus微信小程序,无需安装.卸载,不占用手 ...

  7. 调用微信扫一扫功能,踩坑'invalid signature'

    在vue项目中,调用微信扫一扫功能,在安卓系统下完全正常,ios系统下却报错'invalid signature'的错误,这可能令许多小伙伴困惑,经过查询大量博客相关资料,才找到了解决的方法. 原因: ...

  8. 小程序webview调用微信扫一扫的“曲折”思路

    自上一篇遇到webview中没有返回按钮之后,虽然跳出坑了.解决方案:<小程序webview跳转页面后没有返回按钮完美解决方案> 但是,小程序踩坑之路并没有结束.在公众号网页中通过配置AP ...

  9. 微信支付之扫码支付、公众号支付、H5支付、小程序支付相关业务流程分析总结

    前言 很久以来,一直想写一篇微信支付有关的总结文档:一方面是总结自己的一些心得,另一方面也可以帮助别人,但是因种种原因未能完全理解透彻微信支付的几大支付方式,今天有幸做一些总结上的文章,也趁此机会,将 ...

随机推荐

  1. SQL Server数据库性能优化之索引篇【转】

    http://www.blogjava.net/allen-zhe/archive/2010/07/23/326966.html 性能优化之索引篇 近期项目需要, 做了一段时间的SQL Server性 ...

  2. Java 找不到主类错误

    Eclipse 运行java 程序,突然出现错误:没有或找不到主类. 在网上找了好多办法,都不行. jdk环境配置啊-->这个一般不会出错,因为以前都不会出现这种问题. 查看项目配置啥的--&g ...

  3. VS 自动添加注释

    现在大多数公司都规定程序员在程序文件的头部加上版权信息,这样每个人写的文件都可以区分开来,如果某个文件出现问题就可以快速的找到文件的创建人,用最短的时间来解决问题,常常是以下格式: //======= ...

  4. Yii 多个子目录同步登录

    ---恢复内容开始--- 配置文件中:  1 'components'=>array( 'user'=>array( 'class'=>'CWebUser', 'identityCo ...

  5. STM32——DMA接收和发送的实现

    最近写程序,需要一段一段数据的接收,再通过其他串口发送出去. 老司机们建议用DMA通信,以节约CPU资源.然后,我听了,发现挺好用的.特此,把自己写的代码贴上了. DMA发送接收的步骤如下: 1.初始 ...

  6. 开发板远程操作SQL SERVER解决方案

    环境: 开发板:freescale 2.6 armv71,系统只读,唯一可以读写的路径是/tmp/sd(这是一个sd卡).程序放在/tmp/sd/transfer下(下文以运行路径代替),sql语句以 ...

  7. Dojo的subscribe和publish的简单使用

    问题描述: 假设在你的页面有一个对话框,对话框中包含FilteringSelect这样的需要store的控件,在打开对话框时需要对这个控件做两件事情,一是给该控件的store填充数据,二是要给该控件设 ...

  8. JS 笔记(二) - 函数

    1. 函数的 声明 1) 声明式写法 function j1(id){ alert(id); } 2) 声明匿名函数变量 var j2 = function (a, b) { alert(a + &q ...

  9. tomcat+nginx简单实现负载均衡

    1.环境准备 在前面的博客中我已经安装好nginx和一台tomcat了.现在就在加一台tomcat tomcat1:  /apps/tomcat/tomcat1/apache-tomcat-7.0.6 ...

  10. python 中x%2 x&1 判断偶数奇数 性能对比

    本文使用非常好用的python交互解释器ipython操作演示, 使用命令pip install ipython安装,输入ipython即可.比python自带的好用. python中有两种方法判断一 ...