A client has code written in ActionScript that connects to the server, handles events, and does other work. Working in Flash Professional, you can use ActionScript 3.0 or 2.0. Flash Builder and the Flex SDK use ActionScript 3.0.
For information about learning ActionScript and working with video, see the following resources:
In general, applications require server-side code written in Server-Side ActionScript if they need to do any of the following:
By user name and password, or by credentials stored in an application server or database.
By calling remote methods on clients or updating shared objects that affect all connected clients.
Connect to other servers
By calling a web service or creating a network socket to an application server or database.
Place the server-side code in a file named main.asc or yourApplicationName.asc, where yourApplicationName is a folder in the rootinstall/applications folder. For example, to create an application called skatingClips, create the folder rootinstall/applications/skatingClips. The server-side code would be in a file called main.asc or skatingClips.asc in the skatingClips folder.
The server-side code goes at the top level of the application directory, or in its scripts subdirectory. For example, you can use either of these locations:
By default, the applications folder is in the root installation folder (C:\Program Files\Adobe\Adobe Media Server 5\applications, on Windows). To configure the location of the applications folder, edit the fms.ini or the Vhost.xml configuration file. In the fms.ini file, edit the following parameter: VHOST.APPSDIR = C:\Program Files\Adobe\Adobe Media Server 5\applications. In the Vhost.xml file, edit the AppsDir element.
Server-side scripts have access to two special objects, the Client object and the application object. When a client connects to an application on Adobe Media Server, the server creates an instance of the server-side Client class to represent the client. An application can have thousands of clients connected. In your server-side code, you can use the Client object to send and receive messages to individual clients.
Each application also has a single application object, which is an instance of the server-side Application class. The application object represents the application instance. You can use it to accept clients, disconnect them, shut down the application, and so on.
Some simple text editors might not encode files to the UTF-8 standard. However, some editors provide a Save As option to encode files in the UTF-8 standard.