Link to home
Start Free TrialLog in
Avatar of weinerk
weinerk

asked on

how to detect plugins in MSIE

how to detect plugins in MSIE
meanign
how to find out which plugins are available on the system
using java or javascript or vbscript ?
Avatar of weinerk
weinerk

ASKER

Edited text of question
The way to do this would be to parse the system registry using the langs listed above. Let me know how you go...

Regards,

Jason
Avatar of weinerk

ASKER

need more info than that
how?
ASKER CERTIFIED SOLUTION
Avatar of kolarb
kolarb
Flag of Slovenia image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Check this out! A plugin detection for MSIE(>4?) with VBScript.
It works if the plugin installation updates the
HKEY_CLASSES_ROOT in the windows 95/98 registry, with:
1.a KEY label about the plugin consisting of at least two parts seperated by a dot.
2. The KEY must be in this CLASSES root, having a CLSID subfolder.

This is the function which will search the clients windows registry for the excistance of a KEY label with a CLSID subfolder:

<SCRIPT LANGUAGE=VBScript> <!--

Function CheckWritePlug(PlugInName)
      'This is a sample VBScript comment, ignored by interpreter
         'ErrorHandling becomes ours, avoid those error popups
on error resume next

         'Now checking the registry for KEY label...
         'and assigning returning value to our variable
PlugInDetect = IsObject(CreateObject(PlugInName)) 'This is it!

         'If there was an error(like not exist!),drop the case...
Err.Raise

          'So this conditional, works properly...
 If PlugInDetect = True Then                        
   document.write "True"
 Else
   document.write "False"
 End If

End Function

CheckWritePlug("Microsoft.ActiveXPlugin")            
CheckWritePlug("Microsoft.ActiveXPlugin.1")            
CheckWritePlug("Amovie.ActiveMovie Control")            
CheckWritePlug("Amovie.ActiveMovie Control.1")            
CheckWritePlug("RealPlayer.RealPlayer(tm) ActiveXControl (32-bit)")
CheckWritePlug("RealPlayer.RealPlayer(tm) ActiveX Control (32-bit).1")
CheckWritePlug("ShockwaveFlash.ShockwaveFlash")
CheckWritePlug("ShockwaveFlash.ShockwaveFlash.2")
CheckWritePlug("ShockwaveFlash.ShockwaveFlash.3")
CheckWritePlug("MSVRML2C.VRMLBrowserCtl")
CheckWritePlug("MSVRML2C.VRMLBrowserCtl.1")
CheckWritePlug("PDF.PdfCtrl.1")
CheckWritePlug("LM.LMReader.1")
CheckWritePlug("EYEDOG.EYEDOGCtrl.1")
CheckWritePlug("LiquidMotion.LMEngine")
CheckWritePlug("LiquidMotion.LMEngine.1")
CheckWritePlug("Marquee.MarqueeCtl")
CheckWritePlug("Marquee.MarqueeCtl.1")

//--></SCRIPT>
The arguments above, feeding the CheckWritePlug Function,
could all reliably be detected on my machine.
The argument CheckWritePlug will be fed at call really must be exactly the same as the (default) installation KEY label in the registry.
If it works on your machine it should perform a reliable detection on client machines. Goodluck!
Avatar of weinerk

ASKER

thanks - that looks great!!!!