Home » Software » Adobe Flex

Integrating Flex into Ajax applications Topic:  Adobe Flex
Download (136) times
Last Download at Wednesday 11th of January 2012 10:52:47 AM

Integrating Flex into Ajax applications

If you were looking forward to replacing all your Ajax content with Flex assets, your task would be much simpler. However, this is an unlikely and often unreasonable approach, because there are many reasons to preserve traditional Ajax functionality. ...

Listing 1 demonstrates a stripped-down example of how to use the ExternalInterface class to register an ActionScript function so that JavaScript code can call it. You do this by first defining an ActionScript function, then using the addCallback() method to expose the function to JavaScript for execution. On the HTML side, simply obtain a handle to the Flash container and call the function, which was named using the first parameter to the addCallback() method. Although this demonstration concentrated on exposing functions to the JavaScript code, you can just as easily go the other way by using the call() method of the ExternalInterface class.

The ExternalInterface class can be quite powerful, but there are significant drawbacks to implementing it. To use ExternalInterface, you must be able to write code to implement both the ActionScript and JavaScript environments. This not only requires added skill but double the effort. In this situation, maintaining code as well as two very robust skill sets can become a challenge.

To address the limitations of development against the Flash external API, Adobe has released the FABridge. The FABridge, which ships with the Flex SDK, is a small library used to expose Flash content to scripting in the browser and works in most major browser platforms. With the FABridge, plumbing code that was required to directly implement the Flash external API is now virtually eliminated. Further, the skills required to implement the bridge aren't as robust. As a JavaScript developer, you simply need to be able to understand what's available to you in the way of ActionScript properties and methods. Let's get started with a few examples that demonstrate the capabilities of the FABridge.
...
Source: download.boulder.ibm.com

Download File Read PDF Online

Comments for Integrating Flex into Ajax applications


Related PDF Files

Integrating Adobe Flex and IBM WebSphere Portal

This article is for Flex developers who want to integrate their applications with WebSphe

Developing rich Internet applications for SAP with Adobe Flex

This paper will discuss the Adobe Flex features and architecture, providing an overview of

Importing Skins into Flex Builder

Builder This topic describes how to create skins for Adobe Flex applications by using Adob

Developing AIR Applications with Adobe Flex 3

The Adobe AIR runtime allows you to run AIR applications on the desktop. There are a numbe

Creating Flex Applications with IntelliJ IDEA

In this tutorial you will: Create an IntelliJ IDEA project with Flex-enabled module, Creat

Incoming Search: