Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Determine If User Has Sun's Plugin

Status
Not open for further replies.

JDOne

Programmer
Apr 9, 2003
40
0
0
US
Hi,

How would I write a routine in ASP which would determine if a user has Sun's plugin installed on their system and if so, to link it to its residence for downloading?

Thanks.

J
 
The way I would handle it would be as follows:

Code:
<SCRIPT LANGUAGE="VBScript">
  
on error resume next
  dim m_obj

  Set m_obj = createobject("Sun.object")

  if err.number <> 0 then
       'Send to download page
  else 
       'continue to load content
  end if


</SCRIPT>

This probably isn't the most graceful way of handling this but I know it works. I haven't used it specifically on checking for the SUN plugin but I have used it for checking for real player and other plugins.

Basically I am attempting to load the object. Of course if the object doesn't exist or there is a problem with the object it will prompt an error. You can handle the error and redirect the client to get the appropriate software.

If you post some of you code for the object I might be able to help you taylor it to your needs.

Let me know

Cassidy
 
I appreciate your help. Currently, I have no code yet written. What we've done here is we've upgraded to Sun's JRE plugin and we want to make it available on our intranet so that users that do not have this plugin can download it from our internal server to their worskstations. I don't know what the code syntax is which identifies this particular plugin object. I've been researching it but am having a tough time finding this info out. Do you have any ideas?

Thanks.

J
 
I found the classID for Sun's 1.3.1_12 plugin version.

The next step is to write a routing in asp which checks if the plugin is installed or not. If not, the user will be redirected to a site from which it can be installed. If so, then the applet just launches.

This is the classid: CAFEEFAC-0013-0001-0012-ABCDEFFEDCBA. This would be set in an object tag like this:

<object classid="clsid:CAFEEFAC-0013-0001-0012-ABCDEFFEDCBA" width="600" height="400" align="middle">
<PARAM NAME="CODE" VALUE="myApplet.class">

If anyone can, please show me what the syntax would be to write a simple "if" statement which would check to determine if this particular classID is installed on the user's system or not.

Many Thanks,

J
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top