EasyManua.ls Logo

MACROMEDIA FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE - Escape Function

MACROMEDIA FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE
1378 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
52 ActionScript language elements
Example
In the following example, a new movie clip instance is created called
img_mc. An image is
loaded into the movie clip, and then the
img_mc clip is duplicated. The duplicated clip is
called
newImg_mc, and this new clip is moved on the Stage so it does not overlap the original
clip, and the same image is loaded into the second clip.
this.createEmptyMovieClip("img_mc", this.getNextHighestDepth());
img_mc.loadMovie("http://www.helpexamples.com/flash/images/image1.jpg");
duplicateMovieClip(img_mc, "newImg_mc", this.getNextHighestDepth());
newImg_mc._x = 200;
newImg_mc.loadMovie("http://www.helpexamples.com/flash/images/image1.jpg");
To remove the duplicate movie clip, you could add this code for a button called
myButton_btn.
this.myButton_btn.onRelease = function(){
removeMovieClip(newImg_mc);
};
See also
removeMovieClip function, duplicateMovieClip (MovieClip.duplicateMovieClip
method)
, removeMovieClip (MovieClip.removeMovieClip method)
escape function
escape(expression:String) : String
Converts the parameter to a string and encodes it in a URL-encoded format, where all
nonalphanumeric characters are replaced with % hexadecimal sequences. When used in a
URL-encoded string, the percentage symbol (%) is used to introduce escape characters, and is
not equivalent to the modulo operator (%).
Availability: ActionScript 1.0; Flash Player 5
Parameters
expression:String - The expression to convert into a string and encode in a URL-encoded
format.
Returns
String - URL-encoded string.

Table of Contents

Related product manuals