Publishing and Exporting > Editing Flash HTML settings > Using OBJECT and EMBED
Using OBJECT and EMBED
To display a Flash Player movie in a Web browser, an HTML document must use the OBJECT
and EMBED
tags with the proper parameters.
For OBJECT
, four settings (HEIGHT
, WIDTH
, CLASSID
, and CODEBASE
) are attributes that appear within the OBJECT
tag; all others are parameters that appear in separate, named PARAM
tags. For example:
<OBJECT CLASSID="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" WIDTH="100" HEIGHT="100" CODEBASE="http://active.macromedia.com/flash5/cabs/ swflash.cab#version=5,0,0,0"> <PARAM NAME="MOVIE" VALUE="moviename.swf"> <PARAM NAME="PLAY" VALUE="true"> <PARAM NAME="LOOP" VALUE="true"> <PARAM NAME="QUALITY" VALUE="high"> </OBJECT>
For the EMBED
tag, all settings (such as HEIGHT
, WIDTH
, QUALITY
, and LOOP
) are attributes that appear between the angle brackets of the opening EMBED
tag. For example:
<EMBED SRC="moviename.swf" WIDTH="100" HEIGHT="100" PLAY="true"
LOOP="true" QUALITY="high"
PLUGINSPAGE="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash"
>
</EMBED>
To use both tags together, position the EMBED
tag just before the closing OBJECT
tag, as follows:
<OBJECT CLASSID="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" WIDTH="100" HEIGHT="100" CODEBASE="http://active.macromedia.com/flash5/cabs/ swflash.cab#version=5,0,0,0"> <PARAM NAME="MOVIE" VALUE="moviename.swf"> <PARAM NAME="PLAY" VALUE="true"> <PARAM NAME="LOOP" VALUE="true"> <PARAM NAME="QUALITY" VALUE="high"> <EMBED SRC="moviename.swf" WIDTH="100" HEIGHT="100" PLAY="true" LOOP="true" QUALITY="high" PLUGINSPAGE="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash"> </EMBED> </OBJECT>
Note: If you use both the OBJECT
and the EMBED
tags, use identical values for each attribute or parameter to ensure consistent playback across browsers. The parameter swflash.cab#version=5,0,0,0
is optional, and you can omit it if you don't want to check for version number.
The following tag attributes and parameters describe the HTML created by the Publish command. You can refer to this list as you write your own HTML to insert in Flash movies. Unless noted, all items apply to both OBJECT
and EMBED
tags. Optional entries are noted. When customizing a template, you can substitute a template variable listed here for the value. See Customizing HTML publishing templates.