

function flashInstalled() {
  
    MSDetect = "false";
    if (navigator.plugins && navigator.plugins.length)
    {
    	x = navigator.plugins["Shockwave Flash"];
    	if (x)
    	{
    		return true;
    		if (x.description)
    		{
    			y = x.description;
    		}
    	}
    	else
    		return false;
    	if (navigator.plugins["Shockwave Flash 2.0"])
    	{
    		return true;
    	}
    }
    else if (navigator.mimeTypes && navigator.mimeTypes.length)
    {
    	x = navigator.mimeTypes['application/x-shockwave-flash'];
    	if (x && x.enabledPlugin)
    		return true;
    	else
    		return false;
    }
    else
    	MSDetect = "true";
    
    
    // IE flash detection.
    if (MSDetect == "true") {
    	for(var i=7; i>0; i--){
    		try{
    			var flash = new ActiveXObject("ShockwaveFlash.ShockwaveFlash." + i);
    			return true;
    		}
    		catch(e){
    		}
    	}
    }
 
 return false;   
}
