|
|
| |
Dear
Friend,
Hello, & welcome back to FIREWIRE,
your friendly guide to the exciting world of web-design
& web-solutions! In the previous newsletter of Flash
5 Tutorial Series we had discussed about scripting part
i.e. Introduction to Action Script, Action Palette &
Events. Now lets Continue with Basic Action Script,
Load Movie, Unload Movie, Get URL, Toggle High Quality. |
 |
|
Basic actions help us to control
navigation and user interaction in a movies. Basic actions
are many. The first and most simple action is Goto statement.
Goto
statement: To move from one scene to another
or from one frame to another frame, Goto statement is
used.
Example:
On (press)
{
Goto and play (5);
}
(Or) on (press)
{
Goto and stop (1);
}
We
cannot have Goto statement alone in the script. It is
always clubbed with Play or Stop statement.
| PLAY
& STOP |
|
Using these actions, the movie can be played or
stopped.
The
play and stop are vital commands of action script.
If we uncheck the play button, it automatically
becomes stop. Goto, play and stop statements are
always combined.
Play
and stop statements can be added separately, but
goto statement cannot be separated.
Example:
Like
this, we can have script
On (press)
{
Play ( );
}
On (release)
{
Stop ( );
}
And
not like this:
On
(press)
{
Goto;
}
|
|
 |
|
Using
this command, a movie can be loaded and unloaded.
The load movie is used to load to movie from different
location or from the same location. The URL of
the movie, the target and the variables has to
be specified.

|
| URL
- The specific path of the movie to be loaded.
|
|
Level
- To identify the different movies that
are loaded, we use a number between movies.
|
| Target
- Instance name of the movie. |
| Variables
- To send the values of the movie to server,
use post or get method. The default value
is don't send. |
By specifying the proper values for location,
URL and variables a movie can be loaded. |
|
|
 |
|
In
the unload movie, the level alone is required.
Using the location specify the movie which has
to be unloaded.
If
the level is 1, then specify 1. otherwise, if
the target is "galaxy", specify the
target as "galaxy".

By
specifying the target or level of a movie which
has to be unloaded, unload movie will execute.
Note:
If there is any error in the path or in the values,
the errors will be displayed in the output window.
|
|
|
|
Using
Get URL command, the object can be linked to a
different location. By selecting a button, from
the flash movie, if we want to navigate to another
application and it can be made with the help of
Get URL command.
Syntax : get
URL (url[,window [, variables]]);
URL
- The location to which the link has to be made
is specified in the URL text box.
Window
- an argument which specifies in which window
the document should open.
|
|
_self
- specifies current frame in current
window.
|
|
|
_blank - specifies
a new window. |
|
|
_parent
- specifies the parent of current
frame. |
|
|
_top
- specifies the top frame of current window. |

|
Variables
|
| To
send the variables and the values to server,
we have the following methods:
|
|
|
Get
- appends the value of the variable to the
end of URL. |
|
|
Post
- sends the variables in a separate HTTP header
and it is used for long strings of variables. |
|
 |
|
Using
this command we can maintain the quality
of the movie. This action may affect the
movie, since they give the movie a high
quality and it takes more time to download
the movie due to the large file size.
Syntax:
Toggle high quality ( );
Example:
On (press)
{
toggle high quality ( );
}
Regards,
All accompanying logos,
brands and product names are trademarks
of their respective companies.
|
|
|
|
|
|
|