July 12, 2004

Add Flash to an HTML page

Tearing your hair out trying to add Flash to a web page and make it work in different browsers? Apparently you need to use both OBJECT and EMBED tag syntax. Why? Because IE uses the object tag and Netscape uses Embed. For example:

<OBJECT 
  classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" 
  codebase=
  "http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0" 
  WIDTH="550" HEIGHT="400" id="myMovieName"> 
<PARAM NAME="movie" VALUE="myFlashMovie.swf"> 
<PARAM NAME="quality" VALUE="high"> 
<PARAM NAME="bgcolor" VALUE="#FFFFFF"> 
<EMBED src="myFlashMovie.swf" quality="high" bgcolor="#FFFFFF" 
  WIDTH="550" HEIGHT="400" NAME="myMovieName" ALIGN="" 
  TYPE="application/x-shockwave-flash" 
  PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer"> 
</EMBED> 
</OBJECT>

For those not familiar with the object tag, if it can't display its own content (ie, the movie value) it displays the content of the element (ie, the embed tag).

Technorati tags:

src="http://feeds.feedburner.com/~s/ChaosMagnet?i=http://www.chaosmagnet.com/blog/archives/000458.html" type="text/javascript" charset="utf-8">
Posted by roadnick at July 12, 2004 03:05 AM | TrackBack

Comments

Post a comment









Remember personal info?