HTML Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsWeb DesignHTML Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old November 8th, 1999, 07:56 AM
Damian
Guest
Dev Shed Newbie (0 - 499 posts)
 
Posts: n/a  
Time spent in forums:
Reputation Power:
How can I detect if a plug-in is in the client-browser??

I need to change between a gif image an a flash object, in order the flash plug-in is oris not in the client browser

Thanks!

Reply With Quote
  #2  
Old November 8th, 1999, 12:20 PM
Spookster
Guest
Dev Shed Newbie (0 - 499 posts)
 
Posts: n/a  
Time spent in forums:
Reputation Power:
This will detect if flash is present in Netscape but for IE things work differerntly for detection since they use Active X. Here is for NS:

<HTML>
<HEAD>
<TITLE>Detecting Plugins</TITLE>

<SCRIPT LANGUAGE=JAVASCRIPT TYPE="TEXT/JAVASCRIPT">
<!-- Hide script from old browsers
present = navigator.mimeTypes["application/x-shockwave-flash"];

if (present)
document.write("You have plugin");
else
document.write("You dont have plugin");

// End hiding script from old browsers -->

</SCRIPT>
</HEAD>
<BODY>
</BODY>
</HTML>

You can also use navigator.plugins["name of plugin"] to detect the plugin but you need to know the name of the plugin. Still this only works in NS. Cant help you on IE.

Spookster

Reply With Quote
  #3  
Old November 9th, 1999, 03:43 PM
cruzan
Guest
Dev Shed Newbie (0 - 499 posts)
 
Posts: n/a  
Time spent in forums:
Reputation Power:
At http://www.hotwired.com/webmonkey/javascript/code_library/
you can find a nice vbscript that checks out plugins (flash, shockwave, real, quicktime) and then you can redirect or do a document.write(). This one works very well with IE5 and no complaints yet from IE4 folks. I dont know about Netscape but it does have coding to check Netscape so assume it works (if statement).

Reply With Quote
Reply

Viewing: Dev Shed ForumsWeb DesignHTML Programming > Detect plug-in


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway