Show image if flash is disabled

I've tried using a regular <img> tag, as well as the <asp:image> tag, but neither one works.

What is the smartest way to handle this?

<div class="productGroupTop">
        <asp:HyperLink id="linkage" runat="server">
	<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase=",0,0,0" width="800" height="616" id="RoomImage" align="middle">
	<param name="allowScriptAccess" value="sameDomain" />
	<param name="allowFullScreen" value="false" />
	<param name="movie" value="<%= Page.ResolveUrl("~") %>flash/RoomImage.swf" />
	<param name="quality" value="high" /><param name="bgcolor" value="#ffffff" />	
	<param name="wmode" value="transparent" />
	<embed src="<%= Page.ResolveUrl("~") %>flash/RoomImage.swf"  wmode="transaprent" quality="high" bgcolor="#ffffff" width="800" height="616" name="RoomImage" align="middle" allowScriptAccess="sameDomain" allowFullScreen="false" type="application/x-shockwave-flash" pluginspage="" />
	<asp:Image ID="imgGroupHero" Height="616px" Width="800px" runat="server" AlternateText="no flash" />

Open in new window

Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.


Use a javascript function that detect if Flash is enabled on the browser.

to do so you can use his framework:

<script type="text/javascript"> 
		alert("Flash is required to enjoy this site.");     	
		alert("Flash is insalled on your Web browser.");

Open in new window


Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
I recommend using SWFObject to embed your SWF

the snippet below shows how to do what you need. Basically the alternate content (in your case an image) is replaced at runtime with the SWF if the flash player is detected

documentation is here:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "">
<html xmlns="" lang="en" xml:lang="en">
    <title>SWFObject dynamic embed - step 3</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
    <script type="text/javascript" src="swfobject.js"></script>
    <script type="text/javascript">
    swfobject.embedSWF("myContent.swf", "myContent", "300", "120", "9.0.0");
    <div id="myContent">
      <p>Alternative content -- PUT YOUR ALTERNATE IMAGE HERE</p>

Open in new window

It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.