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 Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Detect Flash Script, if not Flash then display Alternate Image?

Status
Not open for further replies.

EDIx12

Programmer
Jun 19, 2003
4
US
Below is what I am trying to do so far, but I am having problems actually getting it to work. I don't know the sytax in showing the image within the script.

FlashErkennung von Flash Planet is the script I'm trying to use.

<html>

<body>

<SCRIPT LANGUAGE=&quot;JavaScript&quot;>
<!--
var useFlash = navigator.mimeTypes &&
navigator.mimeTypes[&quot;application/x-shockwave-flash&quot;] &&
navigator.mimeTypes[&quot;application/x-shockwave-flash&quot;].enabledPlugin;

//-->

</SCRIPT>
<SCRIPT LANGUAGE=&quot;VBScript&quot;>
<!--
On error resume next
useFlash = NOT IsNull(CreateObject(&quot;ShockwaveFlash.ShockwaveFlash&quot;))
-->

</SCRIPT>
<SCRIPT LANGUAGE=&quot;JavaScript&quot;>
<!--
if ( useFlash ) {
<p><font size=&quot;7&quot; face=&quot;OCRB&quot;><embed width=&quot;129&quot; height=&quot;65&quot; src=&quot;images/eedi.swf&quot;></font></p>;
} else {
<p><img border=&quot;0&quot; src=&quot;images/eedi.gif&quot; width=&quot;130&quot; height=&quot;55&quot;></p>;
}
//-->
</SCRIPT>

</body>

</html>
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top