HTML Code Explained
This is the HTML code you add to a web page to load a Flash applet. The code should be copied-and-pasted to the position you want the applet to appear on the page.

<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0"
width="160" height="276" id="CoolStrip">
<param name="flashvars" VALUE="Copyright=(c) Cool Focus [www.coolfocus.com]">
<param name="movie" VALUE="CoolStrip.swf>
<param name="loop" VALUE="false">
<param name="menu" VALUE="false">
<param name="quality" VALUE="best">
<param name="scale" VALUE="noscale">
<param name="salign" VALUE="LT">
<param name="bgcolor" VALUE="#000000">
<param name="wmode" VALUE="window">
<embed src="CoolStrip.swf" flashvars="Copyright=(c) Cool Focus [www.coolfocus.com]" loop="false" menu="false" quality="best" scale="noscale" salign="LT" bgcolor="#000000" wmode="window" width="160" height="276" swliveconnect="true" name="CoolStrip" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash">
</embed>
</object>

The code contains an <OBJECT> tag and an <EMBED> tag. This is due to the old problem of different browsers supporting different things:

  • If a browser understands the <OBJECT> tag, it will read it (along with the <PARAM> tags that follow it).

  • Browsers that don't understand the <OBJECT> tag will read the <EMBED> tag instead.

This means that the same information must be given twice, once for each tag. We've highlighted the parts of the code that you need to change in bold text, and here's an explanation what each part is for. Remember to make the same change in both the <OBJECT> or <PARAM> tag and in the <EMBED> tag.

  • WIDTH: Sets the width of the applet, in pixels. Most Cool Focus applets have a Testmode parameter which can tell you the best width and height for the applet.

  • HEIGHT: Sets the height of the applet, in pixels.

  • ID (<OBJECT> tag), NAME (<EMBED> tag): Assigns a unique name to the applet, which is used by the script code in the page. If you change the name in the HTML code, you must make the same change in the script code.

  • MOVIE (<OBJECT> tag), SRC (<EMBED> tag): Contains the URL of the applet file (.SWF file). This can be an absolute URL, such as http://www.myserver.com/files/CoolStrip.swf, or a relative URL like ../../files/CoolStrip.swf. The MOVIE/SRC part is explained in more detail here.

  • BGCOLOR: Sets the background color of the applet area. All Cool Focus applets contain a parameter with the same name, and they color the background as soon as they load, but you can use this to make sure the background is the correct color before the applet loads.

  • WMODE (<OBJECT> tag only): This parameter is currently supported by only a few browsers (chiefly Internet Explorer, Firefox and Mozilla). It should usually be set to the word window. If the Cool Focus applet you're using supports transparency and you've set its Transparent parameter to 'yes', WMODE must be set to the word transparent. The final option is to use the word opaque. The 'transparent' and 'opaque' settings cause applets to run slower, but they allow the applet to be positioned or layered on the page using scripting and CSS.

You may not need to change all of the bold text above. Be careful not to change or remove any of the code shown in plain text - in particular, our Copyright notice in the FlashVars parameter and attribute must be included without changes.