We do h5-compliant development or statistics commonly used when judging processing platform, the following are commonly used browser way to judge var UA = inBrowser && window.navigator.userAgent.toLowerCase (); var isIE = UA && / MSIE | Trident / .test (the UA); var isIE9 && UA.indexOf the UA = ( 'MSIE 9.0')> 0; var IsEdge && UA.indexOf the UA = ( 'Edge /')> 0; var isAndroid = (the UA UA.indexOf && ( 'Android')> 0); var isIOS = (&& /iphone|ipad|ipod|ios/.test(UA the UA));
Common browsers way to judge
Guess you like
Origin blog.csdn.net/qq_38694034/article/details/102973599
Ranking