Skip to content

Instantly share code, notes, and snippets.

@datt
Forked from vishaltelangre/flash_support.js
Created May 16, 2013 09:21
Show Gist options
  • Save datt/5590530 to your computer and use it in GitHub Desktop.
Save datt/5590530 to your computer and use it in GitHub Desktop.
// check flash support for visitor browser
function isFlashSupported() {
var hasFlash = false;
try {
var fo = new ActiveXObject('ShockwaveFlash.ShockwaveFlash');
if(fo) hasFlash = true;
}catch(e){
if(navigator.mimeTypes ["application/x-shockwave-flash"] != undefined) {
hasFlash = true;
}
}
return hasFlash;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment