Publishing and Exporting > Publishing Flash movies > Publishing HTML for Flash Player files

Publishing HTML for Flash Player files

Playing a Flash movie in a Web browser requires an HTML document that activates the movie and specifies browser settings. This document is generated automatically by the Publish command, from HTML parameters in a template document.

HTML parameters determine where the Flash movie appears in the window, the background color, the size of the movie, and so on, and set attributes for the OBJECT and EMBED tags. You can change these and other settings in the HTML panel of the Publish Settings dialog box. Changing these settings overrides options you've set in your movie.

Your settings are inserted in a template document. The template document can be any text file that contains the appropriate template variables—including a plain HTML file, one that includes code for special interpreters such as ColdFusion or Active Server Pages (ASP), or a template included with Flash (for more information, see About HTML publishing templates).

You can also customize a template (see Customizing HTML publishing templates), or manually enter HTML parameters for Flash using any HTML editor (see Editing Flash HTML settings).

To publish HTML for displaying the Flash file:

1 Choose File > Publish Settings.
The HTML file type is selected by default.
2 Enter a unique name for Filename, or select Use Default Name to create a file with the Flash file name plus the .html extension.
3 Click the HTML panel to display its settings.
4 Choose an installed template to use from the Template pop-up menu; click the Info button to the right to display a description of the selected template.
The menu lists all of the template files in the Macromedia Flash 5/HTML folder. The basic templates simply display the movie in a browser, and more advanced templates contain code for browser detection and other features. If you don't choose a template, Flash uses the Default.html template, or if that template isn't present, Flash uses the first template in the list.
Flash saves the modified template using the Flash movie's file name plus the template's file extension. For example, if you select a template named Standard.asp for use with a Flash movie named MyMovie.swf, the resulting file would be named MyMovie.asp.
5 Choose a Dimensions option to set the values of the WIDTH and HEIGHT attributes in the OBJECT and EMBED tags:
Choose Match Movie (the default) to use the size of the movie.
Choose Pixels to enter the number of pixels in the Width and Height field.
Choose Percent to use a percentage relative to the browser window.
6 Select Playback options to control the movie's play and features, as follows:
Paused at Start pauses the movie until a user clicks a button in the movie or chooses Play from the shortcut menu. By default, the option is deselected and the movie begins to play as soon as it is loaded (the PLAY parameter is true).
Loop repeats the movie when it reaches the last frame. Deselect this option to stop the movie when it reaches the last frame. (The LOOP parameter is on by default.)
Display Menu displays a shortcut menu when users right-click (Windows) or Control-click (Macintosh) the movie. Deselect this option to display only About Flash in the shortcut menu. By default, this option is on (the MENU parameter is true).
For Windows only, select Device Font to substitute anti-aliased (smooth-edged) system fonts for fonts not installed the on the user's system. Using device fonts increases the legibility of type at small sizes and can decrease the movie's file size. This option only affects movies containing static text (text that you created when authoring a movie and that does not change when the movie is displayed) set to display with device fonts. For more information, see Using device fonts.
Select Quality to determine the trade-off between processing time and applying anti-aliasing to smooth each frame before it is rendered on the viewer's screen, as follows. This option sets the QUALITY parameter's value in the OBJECT and EMBED tags.
Low favors playback speed over appearance and does not use anti-aliasing.
Auto Low emphasizes speed at first but improves appearance whenever possible. Playback begins with anti-aliasing turned off. If the Flash Player detects that the processor can handle it, anti-aliasing is turned on.
Auto High emphasizes playback speed and appearance equally at first but sacrifices appearance for playback speed if necessary. Playback begins with anti-aliasing turned on. If the actual frame rate drops below the specified frame rate, anti-aliasing is turned off to improve playback speed. Use this setting to emulate the View > Antialias setting in Flash.
Medium applies some anti-aliasing, but does not smooth bitmaps. It produces a better quality than the Low setting, but lower quality than the High setting.
High (the default) favors appearance over playback speed and always uses anti-aliasing. If the movie does not contain animation, bitmaps are smoothed; if the movie has animation, bitmaps are not smoothed.
Best provides the best display quality and does not consider playback speed. All output is anti-aliased and bitmaps are always smoothed.
7 For the Windows version of Internet Explorer 4.0 with the Flash ActiveX control, choose a Window Mode option for transparency, positioning, and layering. This option specifies the ALIGN attribute for the OBJECT, EMBED, and IMG tags.
Window plays a Flash Player movie in its own rectangular window on a Web page, for the fastest animation. The option sets the WMODE parameter of the OBJECT tag to WINDOW.
Opaque Windowless moves elements behind Flash movies (for example, with dynamic HTML) to prevent them from showing through, setting the WMODE parameter to OPAQUE.
Transparent Windowless shows the background of the HTML page on which the movie is embedded through all transparent areas of the movie, but may slow animation. The option sets WMODE to TRANSPARENT.
8 Choose an HTML Alignment option to position the Flash movie window within the browser window:
Default centers the movie in the browser window and crops edges if the browser window is smaller than the movie.
Left, Right, Top or Bottom aligns movies along the corresponding edge of the browser window and crop the remaining three sides as needed.
9 Choose a Scale option to place the movie within specified boundaries, if you've changed the movie's original width and height. The Scale option sets the SCALE parameter in the OBJECT and EMBED tags.
Default (Show All) display the entire movie in the specified area without distortion while maintaining the original aspect ratio of the movies. Borders may appear on two sides of the movie.
No Border scales the movie to fill the specified area and keeps the movie's original aspect ratio without distortion, cropping if needed.
Exact Fit displays the entire movie in the specified area without preserving the original aspect ratio, which may cause distortion.
10 Choose a Flash Alignment option to set how the movie is placed within the movie window and how it is cropped, if necessary. This option sets the SALIGN parameter of the OBJECT and EMBED tags.
For Horizontal alignment, choose Left, Center, or Right.
For Vertical alignment, choose Top, Center, or Bottom.
11 Select Show Warning Messages to display error messages if tag settings conflict—for example, if a template has code referring to an alternate image that has not been specified.
12 To save the settings with the current file, click OK.