To use variables to pass a click tracking string into Flash movies, use the clickTAG method as described in Adobe's Designer's Guide article, Tracking Macromedia Flash Movies. Only one set of files is needed to specify the click tracking strings. If the files adhere to the method shown in the Adobe article, the same set of files can be used for multiple campaigns, different sites, and different ad serving networks.
SWF movie requirements for Flash developers
For the most part, the movie is made just like any other Flash movie. Any swf file specifications provided by the site still apply. Any animation or ActionScript that you would normally use can be used with this method. The main difference is in the settings for click-through (getURL) actions.
DFP SWF file requirements
- Flash — Version 6 or higher.
- File names — All lower case characters without ampersands (&), asterisks (*), slashes (/), spaces, or question marks (?).
- Maximum file size — 39KB (default). However, please note that individual sites may restrict the file to a smaller size.
The maximum possible creative size is controlled at the network level. Contact your support representative for more information about changing your maximum file size.
- getURL actions — In general:
- The URL should be
_level0.clickTAG - Set the URL for an expression
- Set the target window to either
_blank(to open a
new window) or _top (to open in the same window). - Set
VariablestoDon't send
For more information, see Flash banner does not track clicks.
- The URL should be
See How do I upload a creative? for more information.
Example: Adding a clickTAG to ActionScript 2.0Create a button on your Flash movie and use getURL() to specify the clickTAG:
getURL (_level0.clickTAG, "_blank");
}
See Adobe's Designer's Guide article, Tracking Macromedia Flash Movies, for more information.
If you use the example below, change 'Link_1' to the instance name of your clickTAG button.
var sURL: String;
if ((sURL = root.loaderInfo.parameters.clickTAG)) {
navigateToURL(new URLRequest(sURL), "_blank");
}
