Created
June 4, 2015 09:31
-
-
Save aisin/efa8d9c4784b4663e5ae to your computer and use it in GitHub Desktop.
判断手机端浏览器是否为微信内置浏览器
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
window.onload = function(){ | |
var ua = window.navigator.userAgent.toLowerCase(); | |
if(ua.match(/MicroMessenger/i) == 'micromessenger'){ | |
return true; | |
}else{ | |
return false; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment