当前位置:网站首页>获取扫码的客户端是微信还是支付宝
获取扫码的客户端是微信还是支付宝
2022-06-25 07:37:00 【youliroam】
获取扫码的客户端是微信还是支付宝
制作的二维码:
1) 支付宝扫码进来是这样滴
2)微信扫码进来是这样滴
3)手机自带浏览器扫码进来是这样滴
4)手机谷歌浏览器打开是这样滴
5)电脑谷歌浏览器打开是这样滴
代码如下:
$(function(){
let client = getClient();
alert(client);
})
function getClient(){
let userAgent = navigator.userAgent.toLowerCase();
alert(userAgent);
if(userAgent.indexOf('micromessenger') != -1){
return 'wechat';
}else if(userAgent.indexOf('alipayclient') != -1){
return 'alipay';
}
if (/ipad|iphone|midp|rv:1.2.3.4|ucweb|android|windows ce|windows mobile/.test(userAgent)) {
return 'mobile';
} else {
return 'computer';
}
}
边栏推荐
- 打新债真的安全吗? 风险大吗
- SharePoint:SharePoint Server 2013 与 ADRMS 集成指南
- Advanced technology Er, meet internship position information
- Problems caused by Gil problems and Solutions
- Is the securities account given by Qiantang education business school safe? Can I open an account?
- Iframe is simple to use, iframe is obtained, iframe element value is obtained, and iframe information of parent page is obtained
- Easyplayer streaming media player plays HLS video. Technical optimization of slow starting speed
- Sharepoint:sharepoint server 2013 and adrms Integration Guide
- 钱堂教育商学院给的证券账户安全吗?能开户吗?
- Paper:Generating Hierarchical Explanations on Text Classification via Feature Interaction Detection
猜你喜欢
A 35 year old Tencent employee was laid off and sighed: a suite in Beijing, with a deposit of more than 7 million, was anxious about unemployment
Wechat applet_ 7. Project practice, local life
Summary of NLP data enhancement methods
在二叉树(搜索树)中找到两个节点的最近公共祖先(剑指offer)
How to calculate the information entropy and utility value of entropy method?
How to calculate the correlation coefficient and correlation degree in grey correlation analysis?
【515. 在每个树行中找最大值】
Data preprocessing: discrete feature coding method
C language: count the number of characters, numbers and spaces
The city chain technology platform is realizing the real value Internet reconstruction!
随机推荐
[operation tutorial] how does the tsingsee Qingxi video platform import the old database into the new database?
What is the file that tp6 automatically executes? What does the tp6 core class library do?
声纹技术(七):声纹技术的未来
How to calculate the information entropy and utility value of entropy method?
想要软件测试效果好,搭建好测试环境是前提
关于I/O——内存与CPU与磁盘之间的关系
Bluecmsv1.6-代码审计
物联网毕设(智能灌溉系统 -- Android端)
配置、软件配置项、软件配置管理项辨析
Getting to know the generation confrontation network (12) -- using pytoch to build wgan-gp to generate handwritten digits
OpenFOAM:底层
To achieve good software testing results, it is a prerequisite to build a good testing environment
How to calculate the positive and negative ideal solution and the positive and negative ideal distance in TOPSIS method?
City Chain technology platform, really Realizing value Internet reconstruction!
在网上股票开户安全吗?证券账户可以给别人用吗?
leetcode. 13 --- Roman numeral to integer
Sampling strategy and decoding strategy based on seq2seq text generation
故障:Outlook 收发邮件时的 0x800CCC1A 错误
Scanpy (VII) spatial data analysis based on scanorama integrated scrna seq
声纹技术(一):声纹技术的前世今生