判断pc端与移动端

isPC:function(){ //判断pc端与移动端

var userAgentInfo = navigator.userAgent;
var Agents = new Array("Android", "iPhone", "SymbianOS", "Windows Phone", "iPad", "iPod"); //判断用户代理头信息
var flag = true;
for (var v = 0; v < Agents.length; v++) {
if (userAgentInfo.indexOf(Agents[v]) != -1) {
flag = false;
break;
}
}
return flag; //true为pc端,false为非pc端
    },

判断pc端与移动端

上一篇:oracle数据库使用distinct多个字段


下一篇:Answer Questions with Right Image Regions: A Visual Attention Regularization Approach