Skip to content

Instantly share code, notes, and snippets.

@tedw
Created November 13, 2012 21:05
Show Gist options
  • Save tedw/4068391 to your computer and use it in GitHub Desktop.
Save tedw/4068391 to your computer and use it in GitHub Desktop.
Check if Flash supported
/* Check if Flash is installed - http://bit.ly/QnBX8L */
var hasFlash = false;
try {
var fo = new ActiveXObject('ShockwaveFlash.ShockwaveFlash');
if(fo) {
hasFlash = true;
}
}
catch(e) {
if( typeof navigator.mimeTypes ["application/x-shockwave-flash"] !== 'undefined' ) {
hasFlash = true;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment