home / experts / javascript / column84 |
|
Checking the Flash PlayerBefore embedding your Flash track, check that the Flash plug-in is installed in Mac or Windows Navigator. The following function,Flash_checkForPlugIn(), does exactly that. It checks that the mimeTypes object exists, that one of the MIME types is flash, and that its relevant plug-in is enabled. The function also extracts the plug-in version, and checks that it is higher than the default minimum player version. The default minimum player version is set as a global variable before calling Flash_checkForPlugIn(). Here is the function in full, preceded by the global variable assignment of minPlayer:
On a Win Internet Explorer system, Flash is implemented as an ActiveX control. The easiest way to check for Flash on such a system is with
And here is the conditional version of the same script. It checks first that the browser is supported, as well as that the system is WIN IE. Only then does it write the VBScript to check that the player is installed and its version is supported. Here is the code:
Next: How to embed a SWF |
Produced by Yehuda Shiran and Tomer Shiran
All Rights Reserved. Legal Notices.
Created: May 21, 2001
Revised: May 21, 2001
URL: http://www.webreference.com/js/column84/3.html