Advertisement
Guest User

Untitled

a guest
May 2nd, 2016
55
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.20 KB | None | 0 0
  1. /**
  2. * Simple regex/user agent mobile checker
  3. * about 99% accurate when compared to 175k sessions in GA
  4. */
  5.  
  6. function isMobile()
  7. {
  8. return window.navigator.match(/Mobi|Touch|Opera\ Mini|Android/)
  9. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement