Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.

  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Chapter 9. Using Complex Services > Data Management in Flash Builder

Data Management in Flash Builder

In this chapter and the last, I’ve been repeatedly using a parallel structure: First I discuss a service-related Flex component and create an example using it (which would work in any development environment), then I create a similar example primarily using Flash Builder’s service-related wizards. By doing so, you’re learning how to develop without Flash Builder (should you choose) and getting a sense of the larger picture, with slight variations on how things can be done. Let’s now create CRUD functionality for the products this same way. Here, though, we’re going to use Flash Builder’s data management support to do a lot of the work. I’ll also use the Zend Framework for the AMF support, as an alternative solution. This means some slight changes are required to the PHP script first.

Updating the PHP Script

One difference between Zend AMF and AMFPHP is that AMFPHP will pass an ActionScript object to the PHP script as an associative array (unless a value object has been defined), but Zend AMF will pass an ActionScript object to the PHP script as a generic object. So let’s quickly update the PHP script accordingly. While we’re at it, I’m going to make some changes to how the inStock value will be returned in the client and tweak the return value of the updateProduct( ) method.


  

You are currently reading a PREVIEW of this book.

                                                                                                                    

Get instant access to over $1 million worth of books and videos.

  

Start a Free Trial


  
  • Safari Books Online
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint