Using an HTML editor, open the Animate HTML template to change. These templates are in the following locations:
- Adobe Animate User Guide
- Introduction to Animate
- Animation
- Animation basics in Animate
- How to use frames and keyframes in Animate
- Frame-by-frame animation in Animate
- How to work with classic tween animation in Animate
- Brush Tool
- Motion Guide
- Motion tween and ActionScript 3.0
- About Motion Tween Animation
- Motion tween animations
- Creating a Motion tween animation
- Using property keyframes
- Animate position with a tween
- How to edit motion tweens using Motion Editor
- Editing the motion path of a tween animation
- Manipulating motion tweens
- Adding custom eases
- Creating and applying Motion presets
- Setting up animation tween spans
- Working with Motion tweens saved as XML files
- Motion tweens vs Classic tweens
- Shape tweening
- Using Bone tool animation in Animate
- Work with character rigging in Animate
- How to use mask layers in Adobe Animate
- How to work with scenes in Animate
- Interactivity
- How to create buttons with Animate
- Convert Animate projects to other document type formats
- Create and publish HTML5 Canvas documents in Animate
- Add interactivity with code snippets in Animate
- Creating custom HTML5 Components
- Using Components in HTML5 Canvas
- Creating custom Components: Examples
- Code Snippets for custom Components
- Best practices - Advertising with Animate
- Virtual Reality authoring and publishing
- Workspace and workflow
- Creating and managing Paint brushes
- Using Google fonts in HTML5 Canvas documents
- Using Creative Cloud Libraries and Adobe Animate
- Use the Stage and Tools panel for Animate
- Animate workflow and workspace
- Using web fonts in HTML5 Canvas documents
- Timelines and ActionScript
- Working with multiple timelines
- Set preferences
- Using Animate authoring panels
- Create timeline layers with Animate
- Export animations for mobile apps and game engines
- Moving and copying objects
- Templates
- Find and Replace in Animate
- Undo, redo, and the History panel
- Keyboard shortcuts
- How to use the timeline in Animate
- Creating HTML extensions
- Optimization options for Images and Animated GIFs
- Export settings for Images and GIFs
- Assets Panel in Animate
- Multimedia and Video
- Transforming and combining graphic objects in Animate
- Creating and working with symbol instances in Animate
- Image Trace
- How to use sound in Adobe Animate
- Exporting SVG files
- Create video files for use in Animate
- How to add a video in Animate
- Draw and create objects with Animate
- Reshape lines and shapes
- Strokes, fills, and gradients with Animate CC
- Working with Adobe Premiere Pro and After Effects
- Color Panels in Animate CC
- Opening Flash CS6 files with Animate
- Work with classic text in Animate
- Placing artwork into Animate
- Imported bitmaps in Animate
- 3D graphics
- Working with symbols in Animate
- Draw lines & shapes with Adobe Animate
- Work with the libraries in Animate
- Exporting Sounds
- Selecting objects in Animate CC
- Working with Illustrator AI files in Animate
- Applying blend modes
- Arranging objects
- Automating tasks with the Commands menu
- Multilanguage text
- Using camera in Animate
- Graphic filters
- Sound and ActionScript
- Drawing preferences
- Drawing with the Pen tool
- Platforms
- Convert Animate projects to other document type formats
- Custom Platform Support
- Create and publish HTML5 Canvas documents in Animate
- Creating and publishing a WebGL document
- How to package applications for AIR for iOS
- Publishing AIR for Android applications
- Publishing for Adobe AIR for desktop
- ActionScript publish settings
- Best practices - Organizing ActionScript in an application
- How to use ActionScript with Animate
- Accessibility in the Animate workspace
- Writing and managing scripts
- Enabling Support for Custom Platforms
- Custom Platform Support Overview
- Working with Custom Platform Support Plug-in
- Debugging ActionScript 3.0
- Enabling Support for Custom Platforms
- Exporting and Publishing
- How to export files from Animate CC
- OAM publishing
- Exporting SVG files
- Export graphics and videos with Animate
- Publishing AS3 documents
- Export animations for mobile apps and game engines
- Exporting Sounds
- Best practices - Tips for creating content for mobile devices
- Best practices - Video conventions
- Best practices - SWF application authoring guidelines
- Best practices - Structuring FLA files
- Best Practices to optimize FLA files for Animate
- ActionScript publish settings
- Specify publish settings for Animate
- Exporting projector files
- Export Images and Animated GIFs
- HTML publishing templates
- Working with Adobe Premiere Pro and After Effects
- Quick share and publish your animations
- Troubleshooting
About HTML publishing templates
An Animate HTML template is a file that contains static HTML code and flexible template code consisting of a special type of variables (which differ from ActionScript variables). When you publish a SWF file, Animate replaces these variables with the values you select in the HTML tab of the Publish Settings dialog box and produces an HTML page with your SWF file embedded.
Animate includes templates, suitable for most users’ needs, that eliminate the need to manually create an HTML page that displays the SWF file. For example, the Animate Only template is useful for testing your files in a browser. It places the SWF file on the HTML page so that you can view it through a web browser with the Flash Player installed.
To publish a new HTML page, use the same template and change the settings. You can create custom templates using any HTML editor. Creating a template is the same as creating a standard HTML page, except that you replace specific values pertaining to a SWF file with variables that begin with a dollar sign ($).
Animate HTML templates have the following special characteristics:
A one-line title that appears on the Template pop‑up menu on the HTML tab of the Publish Settings dialog box.
A longer description that appears when you click Info on the HTML tab of the Publish Settings dialog box.
Template variables beginning with a dollar sign ($) that specify where parameter values should be substituted when Animate generates the output file.
note: Use a backslash and dollar sign (\$) combination to use a dollar sign for another purpose in the document.
HTML object and embed tags that follow the tag requirements of Microsoft Internet Explorer and Netscape® Communicator® or Navigator®, respectively. To display a SWF file properly on an HTML page, follow these tag requirements. Internet Explorer uses the object HTML tag to open a SWF file; Netscape uses the embed tag.
Customize HTML publishing templates
Modify HTML template variables to create an image map, a text report, or a URL report, or to insert custom values for some of the most common Animate HTML object and embed tag parameters (for browsers that use ActiveX controls and plug-ins, respectively).
Animate templates can include any HTML content for your application or even code for interpreters such as ColdFusion and ASP.
-
Windows XP or Vista: boot drive:\Documents and Settings\user\Local Settings\Application Data\Adobe\Flash CS5\language\Configuration\HTML\. The Application Data folder is usually a hidden folder; you might need to change your Windows Explorer settings to see this folder.
Mac OS X 10.3 and later: Macintosh HD/Applications/Adobe Flash CS5/language/First Run/HTML.
The boot drive is the drive from which the Windows operating system boots (usually C:). The user is the name of the person logged in to the Windows operating system. The language is set to an abbreviated language name. For example, in the US, language is set to “en” for English.
-
Edit the template.
-
Save the template in the same folder that you retrieved it from.
-
To apply the template settings to your SWF file, select File > Publish Settings, click HTML, and select the template you modified. Animate changes only the template variables in the template selected.
-
Select your remaining publish settings, and click OK.
HTML template variables
The following table lists the template variables that Animate recognizes:
Attribute/parameter |
Template variable |
---|---|
Template title |
$TT |
Template description start |
$DS |
Template description finish |
$DF |
Animate (SWF file) title |
$T1 |
Animate (SWF file) title for search engine metadata |
$TL |
Description for search engine metadata |
$DC |
Metadata XML string for use with search engines |
$MD |
Width |
$WT |
Height |
$HT |
Movie |
$MO |
HTML alignment |
$HA |
Looping |
$LO |
Parameters for object |
$PO |
Parameters for embed |
$PE |
Play |
$PL |
Quality |
$QU |
Scale |
$SC |
Salign |
$SA |
Wmode |
$WM |
Devicefont |
$DE |
Bgcolor |
$BG |
Movie text (area to write movie text) |
$MT |
Movie URL (location of SWF file URL) |
$MU |
Image width (unspecified image type) |
$IW |
Image height (unspecified image type) |
$IH |
Image filename (unspecified image type) |
$IS |
Image map name |
$IU |
Image map tag location |
$IM |
QuickTime width |
$QW |
QuickTime height |
$QH |
QuickTime filename |
$QN |
GIF width |
$GW |
GIF height |
$GH |
GIF filename |
$GN |
JPEG width |
$JW |
JPEG height |
$JH |
JPEG filename |
$JN |
PNG width |
$PW |
PNG height |
$PH |
PNG filename |
$PN |
Using shorthand template variables
The $PO (for object tags) and $PE (for embed tags) template variables are useful shorthand elements. Each variable causes Animate to insert into a template any nondefault values for some of the most common object and embed parameters, including PLAY ($PL), QUALITY ($QU), SCALE ($SC), SALIGN ($SA), WMODE ($WM), DEVICEFONT ($DE), and BGCOLOR ($BG).
Sample HTML template
The following Default.HTML template file in Animate includes many of the commonly used template variables:
$TTFlash Only $DS Display Adobe SWF file in HTML. $DF <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> $CS <title>$TI</title> </head> <body bgcolor="$BG"> <!--url's used in the movie--> $MU <!--text used in the movie--> $MT <object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.adobe.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0" width="$WI" height="$HE" id="$TI" align="$HA"> <param name="allowScriptAccess" value="sameDomain" /> $PO <embed $PEwidth="$WI" height="$HE" name="$TI" align="$HA" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.adobe.com/go/getflashplayer" /> </object> </body> </html>
Create an image map to substitute for a SWF file
Animate can generate an image map to show any image and maintain the function of buttons that link to URLs. When an HTML template includes the $IM template variable, Animate inserts the image map code. The $IU variable identifies the name of the GIF, JPEG, or PNG file.
-
In your document, select the keyframe to use for the image map and label it #Map in the frame Property inspector (Window > Properties). Use any keyframe with buttons that have attached ActionScript 1.0 or 2.0 getURL actions.
If you don’t create a frame label, Animate creates an image map using the buttons in the last frame of the SWF file. This option generates an embedded image map, not an embedded SWF file.
-
To select the frame to show the image map, do one of the following:
For PNG or GIF files, label the frame to appear as #Static.
For JPEG, during the publish operation, place the playhead on the frame to be used for display.
-
In an HTML editor, open the HTML template you’ll modify.
-
Save your template.
-
Select File > Publish Settings, click Format, select a format for the image map, and click OK.
For example, insert the following code in a template:
$IM <img src=$IS usemap=$IU width=$IW height=$IH BORDER=0>
This might produce the following code in the HTML document that the Publish command creates:
<map name="mymovie"> <area coords="130,116,214,182" href="http://www.adobe.com"> </map> <img src="mymovie.gif" usemap="#mymovie" width=550 height=400 border=0>
Creating text and URL reports
The $MT template variable causes Animate to insert all the text from the current SWF file as a comment in the HTML code. This is useful for indexing the content of a SWF file and making it visible to search engines.
The $MU template variable makes Animate generate a list of the URLs that actions in the current SWF file refer to and insert the list at the current location as a comment. This action lets link verification tools detect and verify the links in the SWF file.
Embedding search metadata
The $TL (SWF file title) and $DC (description metadata) template variables let you include search metadata in the HTML. This ability can make the SWF file more visible to search engines, and provide meaningful search results. Use the $MD template variable to include the search metadata as an XML string.