let agent=window.navigator.userAgent.toLowerCase();
if(agent.indexOf("weixin")!==-1){
document.write("您使用的是微信自带的浏览器");
}else if(agent.indexOf("iphone")!==-1){
document.write("您使用的是苹果手机设备");
}else if(agent.indexOf("ipad")!==-1){
document.write("您使用的是苹果平板设备");
}else if(agent.indexOf("android")!==-1){
document.write("您使用的是安卓设备");
}
04-12
614
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
10-17
1589
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)