userAgent判断客户端,以及各个浏览器的ua
http://blog.csdn.net/yoyoosyy/article/details/70142884
navigator.userAgent.match(/Android/i) //安卓客户端浏览器
navigator.userAgent.indexOf('iPhone') != -1) //iPhone手机客户端
navigator.userAgent.indexOf('iPod') != -1) //iPod 客户端
navigator.userAgent.indexOf('iPad') != -1 //iPad 客户端
<pre class="js" style="" name="code">
if(navigator.userAgent.match(/Android/i)||(navigator.userAgent.indexOf('iPhone') != -1) || (navigator.userAgent.indexOf('iPod') != -1) || (navigator.userAgent.indexOf('iPad') != -1)) {
$("#common_header,#common_navbar,#backtotop,#footer").hide();
}
</pre><br><br><br>
<p style="">uc:</p>
<p style="">Mozilla/5.0 (Linux; U;<span> </span><strong style="font-weight:700">Android</strong><span> </span>4.4.2; zh-CN; NX505J Build/KVT49L) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0<span> </span><strong style="font-weight:700">UCBrowser</strong>/10.5.2.598 U3/0.8.0 Mobile Safari/534.30</p>
<p style="">Mozilla/5.0 (iPhone; CPU<span> </span><strong style="font-weight:700">iPhone</strong><span> </span>OS 9_3_3 like Mac OS X; zh-CN) AppleWebKit/537.51.1 (KHTML, like Gecko) Mobile/13G34<span> </span><strong style="font-weight:700">UCBrowser</strong>/10.9.19.815 Mobile<br style=""></p>
<p style="">手机百度:</p>
<p style="">Mozilla/5.0 (Linux;<span> </span><strong style="font-weight:700">Android</strong><span> </span>4.4.2; NX505J Build/KVT49L) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/35.0.1916.138 Mobile Safari/537.36 T7/7.1<strong style="font-weight:700">baiduboxapp</strong>/7.5.1 (Baidu; P1 4.4.2)<br style=""></p>
<p style="">Mozilla/5.0 (iPhone; CPU<span> </span><strong style="font-weight:700">iPhone</strong><span> </span>OS 9_3_3 like Mac OS X) AppleWebKit/601.1.46 (KHTML, like Gecko) Mobile/13G34<strong style="font-weight:700">baiduboxapp</strong>/0_7.0.5.7_enohpi_4331_057/3.3.9_1C2%258enohPi/1099a/B80ADBCDA918AA94450DE8767C97BC446249D6087FCLPRHEEPF/1<br style=""></p>
<p style="">百度浏览器:<br style=""></p>
<p style="">Mozilla/5.0 (Linux;<span> </span><strong style="font-weight:700">Android</strong><span> </span>4.4.2; NX505J Build/KVT49L) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/35.0.1916.138 Mobile Safari/537.36 T7/7.2<strong style="font-weight:700">baidubrowser</strong>/7.3.14.0 (Baidu; P1 4.4.2)</p>
<p style="">Mozilla/5.0 (iPhone; CPU<span> </span><strong style="font-weight:700">iPhone</strong><span> </span>OS 9_3_3 like Mac OS X) AppleWebKit/601.1.46 (KHTML, like Gecko) Version/9.3 Mobile/13G34 Safari/600.1.4<strong style="font-weight:700">baidubrowser</strong>/4.2.0.324 (Baidu; P2 9.3.3)<br style=""></p>
<p style="">qq:</p>
<p style="">Mozilla/5.0 (Linux;<span> </span><strong style="font-weight:700">Android</strong><span> </span>4.4.2; NX505J Build/KVT49L) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/37.0.0.0 Mobile<span> </span><strong style="font-weight:700">MQQBrowser</strong>/6.2 TBS/036555 Safari/537.36 V1_AND_SQ_6.3.7_374_YYB_D PA QQ/6.3.7.2795 NetType/WIFI WebP/0.3.0 Pixel/1080<br style=""></p>
<p style="">Mozilla/5.0 (iPhone; CPU<span> </span><strong style="font-weight:700">iPhone</strong><span> </span>OS 9_3_3 like Mac OS X) AppleWebKit/601.1.46 (KHTML, like Gecko) Mobile/13G34<span> </span><strong style="font-weight:700">QQ</strong>/6.5.0.443 V1_IPH_SQ_6.5.0_1_APP_A Pixel/750 Core/UIWebView NetType/WIFI Mem/41<br style=""></p>
<p style="">qq空间:</p>
<p style="">Mozilla/5.0 (Linux;<span> </span><strong style="font-weight:700">Android</strong><span> </span>4.4.2; NX505J Build/KVT49L) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/37.0.0.0 Mobile<span> </span><strong style="font-weight:700">MQQBrowser</strong>/6.2 TBS/036555 Safari/537.36 V1_AND_SQ_6.3.7_374_YYB_D QQ/6.3.7.2795 NetType/WIFI WebP/0.3.0 Pixel/1080<br style=""></p>
<p style="">Mozilla/5.0 (iPhone; CPU<span> </span><strong style="font-weight:700">iPhone</strong><span> </span>OS 9_3_3 like Mac OS X) AppleWebKit/601.1.46 (KHTML, like Gecko) Mobile/13G34<span> </span><strong style="font-weight:700">QQ</strong>/6.5.0.443 V1_IPH_SQ_6.5.0_1_APP_A Pixel/750 Core/UIWebView NetType/WIFI Mem/169<br style=""></p>
<p style="">qq浏览器:</p>
<p style="">Mozilla/5.0 (Linux; U;<span> </span><strong style="font-weight:700">Android</strong><span> </span>4.4.2; zh-cn; NX505J Build/KVT49L) AppleWebKit/537.36 (KHTML, like Gecko)Version/4.0 Chrome/37.0.0.0<strong style="font-weight:700">MQQBrowser</strong>/6.8 Mobile Safari/537.36<br style=""></p>
<p style="">Mozilla/5.0 (iPhone 6s; CPU<span> </span><strong style="font-weight:700">iPhone</strong><span> </span>OS 9_3_3 like Mac OS X) AppleWebKit/601.1.46 (KHTML, like Gecko) Version/6.0<span> </span><strong style="font-weight:700">MQQBrowser</strong>/6.8.1 Mobile/13G34 Safari/8536.25 MttCustomUA/2<br style=""></p>
<p style="">微信:</p>
<p style="">Mozilla/5.0 (Linux;<span> </span><strong style="font-weight:700">Android</strong><span> </span>4.4.2; NX505J Build/KVT49L) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/37.0.0.0 Mobile MQQBrowser/6.2 TBS/036548 Safari/537.36<span> </span><strong style="font-weight:700">MicroMessenger</strong>/6.3.18.800 NetType/WIFI Language/zh_CN<br style=""></p>
<p style="">Mozilla/5.0 (iPhone; CPU iPhone OS 9_3_3 like Mac OS X) AppleWebKit/601.1.46 (KHTML, like Gecko) Mobile/13G34<span> </span><strong style="font-weight:700">MicroMessenger</strong>/6.3.23 NetType/WIFI Language/zh_CN<br style=""></p>
<p style="">微博:</p>
<p style="">Mozilla/5.0 (Linux;<span> </span><strong style="font-weight:700">Android</strong><span> </span>4.4.2; NX505J Build/KVT49L) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/30.0.0.0 Mobile Safari/537.36<span> </span><strong style="font-weight:700">Weibo</strong><span> </span>(nubia-NX505J__weibo__6.8.0__android__android4.4.2) tae_sdk_a_2.0.0 AliApp(BC/2.0.0)<br style=""></p>
<p style="">Mozilla/5.0 (iPhone; CPU<span> </span><strong style="font-weight:700">iPhone</strong><span> </span>OS 9_3_3 like Mac OS X) AppleWebKit/601.1.46 (KHTML, like Gecko) Mobile/13G34<span> </span><strong style="font-weight:700">Weibo</strong>(iPhone8,1__weibo__6.8.1__iphone__os9.3.3) AliApp(BC/2.1) tae_sdk_ios_2.1 havana</p>
<br>
userAgent判断客户端,以及各个浏览器的ua的更多相关文章
- 如何通过navigator.userAgent判断是哪款浏览器?
userAgent 用户代理.通过浏览器控制台alert( navigator.userAgent );可以获得当前浏览器的信息,如果逆推呢? 通过navigator.userAgent判断是哪款浏览 ...
- 根据User Agent参数的各个字段Mozilla/5.0/4.0-AppleWebKit/Chrome/Safari/Firefox/Opera/MSIE来确定/判断客户端使用什么浏览器
下面给你一一解答以及给你介绍: //Mozilla/5.0 (Windows; U; Windows NT 5.1; zh-CN) AppleWebKit/533.21.1 (KHTML, like ...
- php 通过http user-agent判断是否为手机浏览器
<?php/*** 判断是否是通过手机访问* @return bool 是否是移动设备 */public function isMobile() { //判断手机发送的客户端标志 if ...
- JS判断客户端是否是iOS或者Android或者ipad(三)
* * @function: 判断浏览器类型是否是Safari.Firefox.ie.chrome浏览器 * @return: true或false * */ function isSafa ...
- H5案例分享:使用JS判断客户端、浏览器、操作系统类型
使用JS判断客户端.浏览器.操作系统类型 一.JS判断客户端类型 JS判断客户端是否是iOS或者Android手机移动端 通过判断浏览器的userAgent,用正则来判断手机是否是ios和Androi ...
- HTTP请求中的User-Agent 判断浏览器类型的各种方法 网络爬虫的请求标示
我们知道,当用户发送一个http请求的时候,浏览的的版本信息也包含在了http请求信息中: 如上图所示,请求 google plus 请求头就包含了用户的浏览器信息: User-Agent:Mozil ...
- JS判断客户端、浏览器、操作系统
一.JS判断客户端是否是iOS或者Android手机移动端 通过判断浏览器的userAgent,用正则来判断手机是否是ios和Android客户端. 方法一: var u = navigator.us ...
- 使用JS判断客户端、浏览器、操作系统类型
一.JS判断客户端类型 JS判断客户端是否是iOS或者Android手机移动端 通过判断浏览器的userAgent,用正则来判断手机是否是ios和Android客户端. 核心代码如下: 方法一: &l ...
- JS判断浏览器类型,JS判断客户端操作系统
JS判断浏览器类型 function judge(){ var browser = { versions: function() { var u = navigator.userAgent, app ...
随机推荐
- CSU 1364 Interview RMQ
题意: 瑶瑶有一家有一家公司,最近他想招m个人.因为他的公司是如此的出名,所以有n个人来参加面试.然而,瑶瑶是如此忙,以至于没有时间来亲自面试他们.所以他准备选择m场面试来测试他们. 瑶瑶决定这样来安 ...
- UML 绘图关系
1 继承 子类继承父类 2 实现 实现类实现接口 3 依赖 (偶然.临时.比较弱关联) 类 A 使用了类 B,如果类 B 产生变化将会影响类A ...
- [Python] Histograms for analysis Daily return
A histogram is an accurate representation of the distribution of numerical data. Y axis is the occur ...
- [Python] Accessing Array Elements
NumPy Reference: Indexing Note: Indexing starts at 0 (zero). def slicing(): a = np.random.rand(5,4) ...
- WireGuard 隧道的安装和使用,测试地址 ca.6tu.me
WireGuard 端到端平等的网络隧道,测试地址 ca.6tu.me --------------------------------------------- 服务器:远程 Ubuntu18 , ...
- Word 操作组件介绍 - Spire.Doc
http://www.cnblogs.com/liqingwen/p/5898368.html
- orm 通用方法——DeleteModel 主键删除
定义代码: /** * 描述:删除对象 * 作者:Tianqi * 日期:2014-09-17 * param:model 对象实例,包含主键 * return:int 受影响行数 * return: ...
- Fishing Net
In a highly modernized fishing village, inhabitants there make a living on fishery. Their major tool ...
- BZOJ2668: [cqoi2012]交换棋子(费用流)
Description 有一个n行m列的黑白棋盘,你每次可以交换两个相邻格子(相邻是指有公共边或公共顶点)中的棋子,最终达到目标状态.要求第i行第j列的格子只能参与mi,j次交换. Input 第一行 ...
- 使用scatter画散点图
刚开始接触Python,照着例子写的代码,百度注释的. from numpy import * import matplotlib import matplotlib.pyplot as plt im ...