The Book at a Glance

This is the first edition of Flash Remoting: The Definitive Guide. It covers new ground because Flash Remoting is a relatively new technology. Most of the examples in the book centralize the code on the first frame of the timeline or in an external include file.

Flash Remoting works with several different server-side technologies. You should skim the sections that cover alternative server models, as they contain useful nuggets applicable to other platforms. Each chapter may be read individually or as parts of a whole. The first three chapters will be crucial to understanding Flash Remoting and should be read sequentially.

The chapter breakdown is as follows.

Part I: Remoting Fundamentals

Part I covers the setup and installation of Flash Remoting and offers a basic introduction to its use. It also offers details on core concepts and Remoting internals.

Chapter 1

A general introduction to Flash Remoting and related technologies. It implements a sample “Hello World” application for all supported platforms, which demonstrates the simplicity of the technology.

Chapter 2

Gives a complete rundown of what is needed to implement Flash Remoting and describes the basic installation processes for each component. The Flash authoring interface is described as it relates to Flash Remoting.

Chapter 3

The Flash MX UI components are covered as they relate to Flash Remoting, along with several components released as commercial add-ons by Macromedia. In addition, techniques to build forms in Flash MX are described. Examples highlight each key point.

Chapter 4

Explains the Flash Remoting API by dissecting the various classes that are installed when you install the Flash Remoting components and methods of those classes. Again, each important point is shown using examples that you can run on your own system.

Part II: The Server-Side Languages

Part II covers the server-side environments that Flash can communicate with via Flash Remoting.

Chapter 5

ColdFusion is perhaps the easiest and most popular of the different server-side models available to Flash Remoting, and this chapter shows various techniques for using Flash Remoting with ColdFusion.

Chapter 6

Server-Side ActionScript (SSAS) allows Flash MX developers to develop server-side code using the familiar ActionScript syntax instead of ColdFusion or Java. ColdFusion and JRun servers can both execute Server-Side ActionScript using a built-in parser based on the open source Rhino implementation of JavaScript.

Chapter 7

Flash Remoting lets developers enhance any J2EE (i.e., Java) application. This chapter covers applications that run on supported J2EE servers, including Macromedia’s JRun 4 server and IBM’s WebSphere.

Chapter 8

Microsoft’s Active Server Pages (ASP) technology is being phased out in favor of ASP.NET. Flash Remoting works well with ASP.NET but does not support ASP. This chapter covers the idiosyncrasies of the ASP.NET implementation by building several real-world examples.

Chapter 9

The PHP technology is an open source server platform that attracts many users. Macromedia did not release a version of Flash Remoting for PHP, but a group of developers have created an open source solution. This chapter covers the PHP implementation, AMFPHP.

Part III: Advanced Flash Remoting

Part III covers advanced Flash Remoting techniques.

Chapter 10

Flash Remoting allows Flash to interface with SOAP-based web services, regardless of the server-side language with which the web service is implemented. This chapter covers both basic and advanced techniques for publishing and communicating with remote web services.

Chapter 11

Flash’s built-in UI components and ActionScript objects can be extended to offer more functionality. This chapter examines several objects and components and explains how to extend functionality to enhance Flash Remoting.

Chapter 12

Expands on earlier chapters by showing some common best practices that an ActionScript programmer can use with Flash Remoting, such as handling server-side results and errors, organizing code, and clearly separating the UI from the server-side functionality.

Chapter 13

Flash supports important debugging tools for serious application development. This chapter explains the ActionScript and NetServices debuggers, as well as general techniques for both client-side and server-side debugging.

Chapter 14

Demonstrates building a simple script repository, including the inserting, updating, deleting, and displaying of data from a database and the uploading, downloading, and storing of scripts.

Chapter 15

A Flash Remoting API reference that you will refer to as you build your Flash Remoting applications.

Part IV: Appendixes

Appendix A

Covers datatype conversion from Flash Remoting to the different server-side languages.

Appendix B

Lists other resources covering Flash Remoting or related technologies.

Appendix C

Includes details of the user interface specification and implementation of the real-world script repository application demonstrated in Chapter 14.

Terminology Conventions

The word Flash has different meaning in different contexts, such as a browser plugin or the authoring environment. This book follows these naming conventions:

Flash

Refers generically to Flash movies and the Flash technology.

Flash MX

Refers to the Flash MX authoring environment.

Flash MX 2004 (Flash 2004)

Refers to the Flash 2004 authoring environment. Flash 2004, released in September 2003, is the sequel to Flash MX. Flash Remoting in Flash 2004 is the same as Flash Remoting in Flash MX.

Flash MX Professional 2004 (Flash Pro)

Refers to the Flash Pro authoring environment. Flash Pro offers all the features of Flash 2004, plus a forms-based UI and some additional components. Flash Remoting in Flash Pro is the same as Flash Remoting in Flash 2004 and Flash MX, although there is additional support for access to SOAP-based web services.

Flash Player 7, Flash Player 6, or Flash Player

Refers to the browser plugin that allows users play .swf files (movies). I use the term plugin, even though the Flash Player is an ActiveX control in Internet Explorer. If we use the generic term Flash Player in relation to Flash Remoting, you can assume we mean Flash Player 6 or later. Flash Player 7 has built-in support for SOAP-based web services without requiring a server-side installation.

Flash 5

Refers to the Flash 5 authoring environment. Flash 5 does not support Flash Remoting.

Flash Player 5

Refers to the earlier browser plugin. Flash Player 5 does not support Flash Remoting.

Standalone Player

Refers to the Flash Player that runs on the local system without needing the browser. The Standalone Player for Flash MX or later supports Flash Remoting, but earlier Standalone Players (i.e., Flash 5 and earlier) do not.

Flash Remoting

Refers generically to the technology that includes the ability to communicate between Flash and some server-side component, including the server-side software that supports Flash Remoting and the AMF message format.

Flash Remoting MX and Flash Remoting gateway

Both terms refer to the server-side modules needed for each server model. For ColdFusion, it is a native service (a Java servlet); in ASP.NET it’s an assembly; in Java servers, it runs as a servlet; in PHP, it is a class.

Flash Remoting Components

Refers to the downloadable components from Macromedia that you have to install into the Flash authoring environment in order to work with Flash Remoting.

ColdFusion MX

Refers to the Macromedia ColdFusion MX application server.

ColdFusion Markup Language (CFML) and ColdFusion

Both terms refer to the ColdFusion programming language in which .cfm pages are implemented.

J2EE server

Refers to Java 2 Enterprise Edition servers, such as JRun 4 or IBM’s WebSphere.

Java server

Refers to other implementations of Java servlet technologies, such as Tomcat, that don’t necessarily support the J2EE specification.

Java

Refers to the programming language used to build J2EE and Java server applications.

Typographical Conventions

This book follows these typographical conventions:

Menu options

These are shown separated by the character, such as File New or Modify Align To Stage.

Constant width

Used for directives, variable names, property names, parameter names, ColdFusion markup tags, and code samples. It also denotes code within the text.

Italic

Italics indicate function names, object names, class names, directory names, commands, filenames, and file suffixes such as .swf or URLs such as http://www.macromedia.com/index.html. Italics are also used for emphasis, such as when introducing a new term to the reader. Functions or methods will usually be followed by parenthesis, like myFunction( ).

Constant width bold

Indicates that the reader should enter something verbatim. It is sometimes used within code samples for emphasis.

Constant width italic

Indicates a placeholder that should be substituted with your own value, such as myServiceName. It can also be used for emphasis within code comments. Optional items are also sometimes shown in square brackets.

Some sections of text that require special attention will be set apart from the text with the following icons:

Tip

This is a tip. A tip either reiterates an important point, offers a tidbit of information that relates to the current discussion, or brings to your attention an item that is crucial to understanding the topic at hand.

Warning

This is a warning. A warning describes some aspect of the current topic that needs careful attention so that you can avoid possible problems down the road.

Get Flash Remoting: The Definitive Guide 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.