Hello World application
Overview
Note: The following sections apply to Flash Media Interactive Server and Flash Media Development Server.
This example uses Flash CS3 to show how to connect a Flash file to a server-side script and how to request infor-
mation from the server. In this example, the Flash interface has one button (Connect) and one label (initially blank).
When a user clicks the Connect button, the client connects to the server; then the client calls a server-side function
to return a string value. When the server replies, the client's responder function displays the returned string in the
label. The client continues by changing the button's label to Disconnect. When the Disconnect button is clicked, the
client closes the connection and clears the label.
The example files are in the HelloWorld directory.
Create the user interface
Start Flash CS3 and select Create New > Flash File (ActionScript 3.0).
1
2
In the Document Class field, enter HelloWorld. You may see an ActionScript Class Warning message about a
missing definition—click OK, as you will be adding the class file in the next section.
Choose Windows > Components and select User Interface > Button. On the Properties tab, name the Button
3
.
connectBtn
4
Add a Label component, move it up above the button, and name it
Save the file as HelloWorld.fla.
5
.
textLbl
FLASH MEDIA SERVER
4
Developer Guide
Need help?
Do you have a question about the 65029121 - Flash Media Streaming Server and is the answer not in the manual?