Created
July 3, 2017 03:09
-
-
Save adiwids/bbef316ac51a0964f07c179f27fd608f to your computer and use it in GitHub Desktop.
This file contains hidden or 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.isMacLike = function() { | |
return navigator.platform.match(/(Mac|iPhone|iPod|iPad)/i); | |
} | |
window.isiOS = function() { | |
return navigator.userAgent.match(/ipad|iphone|ipod/i); | |
}; | |
window.isAndroid = function() { | |
return navigator.userAgent.match(/android/i); | |
}; | |
window.flashDisabled = function() { | |
return swfobject.getFlashPlayerVersion().major == 0 ? true : false; | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment