This is the Title of the Book, eMatter Edition
Copyright © 2007 O’Reilly & Associates, Inc. All rights reserved.
118
|
Chapter 4: Applications, Instances, and Server-Side ActionScript
Two instances should never directly attempt to update the same
shared object. If more than one instance needs to use a shared object,
it should be done via a NetConnection between the instances.
Usually, one instance is selected as the owner of the shared object or stream and the
other instances connect to it in order to access its resources. Interinstance communi-
cations is covered in detail later in this chapter and in Chapter 16.
Differences Between Flash ActionScript and
Server-Side ActionScript
As alluded to earlier in this chapter and the Preface, there are two distinct types of
ActionScript: client-side ActionScript—which includes both ActionScript 1.0 and
ActionScript 2.0—and the server-side version, known as Server-Side ActionScript.
Client-side ActionScript is used to create .swf movies, which run in the Flash Player
on the user’s machine. Server-Side ActionScript is stored in .asc files that run on the
FlashCom Server.
Since Flash 5, client-side ActionScript has been based on the ECMA (European Com-
puter Manufacturers Association) standards, as is JavaScript. The standard language
is named ECMAScript and is defined in ECMA-262 available at: http://www.ecma-
international.org. Client-side Flash ActionScript has never completely conformed to
the ECMAScript standard because Macromedia developed the language with its
unique needs and backward compatibility in mind. Client-side ActionScript has also
evolved over time. The earlier implementation supported in Flash MX (and still sup-
ported in Flash MX 2004) has been retroactively dubbed ActionScript 1.0. The latest
implementation—supported in Flash MX 2004 and closer to ECMA compliance
than earlier implementations—is named ActionScript 2.0. For more information on
the differences between Flash ActionScript 1.0 and ECMAScript, see Appendix D in
ActionScript for Flash MX: The Definitive Guide (O’Reilly). For details on
ActionScript 2.0 and how it diverges from the ECMA standards, see Essential Action-
Script 2.0, also from O’Reilly.
Contrary to client-side ActionScript, Server-Side ActionScript conforms to the
ECMAScript standard because Macromedia used the Mozilla Spidermonkey
JavaScript 1.5 interpreter in FlashCom. More information on it and JavaScript 1.5
are available here:
http://www.mozilla.org/js
This section outlines the differences that you should watch out for between client-
side ActionScript and Server-Side ActionScript.

Get Programming Flash Communication Server now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.