Legal
The views expressed in this blog are my own and do not necessarily reflect the views of Adobe Systems Incorporated.
Search
October 18, 2006
Flex and Ajax Working Together
The team over at Nitobi, world leaders in enterprise Ajax components, have put together a great demo showing Flex working side by side with their Ajax components. Dave Johnson blogs about the demo, which shows a Flex graph being populated with data using the Flex / Ajax bridge. Under the hood, they're using PHP and MySQL to provide the data for the grids and the charts. They've also got a nice article up on how they built the demo.technorati tags:flex, ajax, fabridge
July 25, 2006
Ajax, JSON, PHP, and Flex together to build a Flash-y Ajax site
In honor of the O'Reilly Open Source conference that I and other Adobe people at attending, I'm happy to show an example of building out a site that combines Ajax, JSON, PHP, and Flex into one application, with 90% of this being done with open source software (the only piece that is not open source, but is free (in terms of cost), is the Flex SDK). I've created a site that tries to mimics the experience of Google Finance, a great site that combines Ajax, and Flash together to provide a great user experience.
This tutorial, available online in PDF format with complete source code in this .zip file, shows how to take data from your Feedburner feed, and create an Ajax application that displays the dates and hits of your feed. It will then take that information and populate a graph that we've created with Flex and the Adobe Flex Charting components, using the Flex / Ajax bridge from Ely Greenfield and the JSON ActionScript library from Mike Chambers, Christian Cantrell, Daniel Dura, and Darron Schall.
A working example of this is available on our wickeddemo.com website. (Note that because of load, that example will load data from a static XML file, rather than PHP.)
If you have any questions about this example, please post there here in this blog.
Here is what I've learned in using the Spry Ajax framework and Flex together:
I found it easiest to modify the HTML that gets output by Flex Builder, rather than to reference the built swf file in my own HTML file that I create. If you do that, be sure to modify index.template.html in the html-template/ folder of your Flex project, rather than the .html files in the bin/ directory of your Flex project. The HTML files in bin/ get overwritten when you save and re-build your Flex application, and if you modify those, rather than index.template.html, you'll lose your changes to index.template.html.
I started building out the Flex graph using JavaScript and the Flex / Ajax bridge. I don't recommend that. Build out your entire Flex component in Flex Builder, then simply write functions to pass data to it from HTML. I think that's easier than trying to build Flex components using JavaScript.
Similarly, write functions that closely couple your Flex application to your HTML page. For instance, you'll notice that in my MXML file, I call the chartClicked JS function using:
if( ExternalInterface.available )
ExternalInterface.call("chartClicked",clickEvent.hitData.item);I could have attached an observer to the lineChart instead, using the Flex / Ajax bridge, but I find it easier to get the data items and debug the application in Flex Builder, rather than trying to do that in JavaScript on the HTML page.
The ActionScript 3 JSON library doesn't like new lines or carriage returns in the JSON data. You need to strip those out before sending data from JS to ActionScript over the Flex / Ajax bridge.
- I don't know of any other technologies that I could use in this tutorial to get a higher click through on MXNA. Well, maybe Web 2.0. :)
technorati tags:flex, ajax, php, web2.0, json, adobe, flash
Blogged with Flock
July 6, 2006
Adobe Developer Week Recorded Sessions
In case you missed the sessions we had during Adobe Developer Week, they've all been recorded. There's information on Adobe Apollo, LiveCycle, Flex, ColdFusion, Flex and LiveCycle, security, Ajax, and more. Check them out at your leisure.
technorati tags:apollo, adobe, livecycle, ajax, flex2, coldfusion
Blogged with Flock
June 29, 2006
Why open source developers can be excited about Flex
The goal of open source software has always been to create software that can be free, not in price but in terms of restrictions for use. The availability of source code and the the ability to modify that source code, are important parts in the free / open source software movement.
There is lots of good news with respect to today's Flex launch for open source developers. First of all, the free Flex SDK includes the source code for the Flex components, and allows anyone to compile a Flex application at no cost. You are free to modify the Flex components as you need to. As a developer, you can now build a Flash application in VIM, run it through the compiler in the SDK, which works on Linux and Mac OS X, and build a .swf file. (In fact, if you're using VIM, you might want to check out actionscript.vim by Manish Jethani to highlight your ActionScript source code in VIM). For debugging, you can use fdb, part of the Flex SDK.
The Flex Builder tool is built on top of Eclipse, and we have published the source code for Flex Builder that is derived from Eclipse.
You can create open source Flex applications, and host them over at osflash.org. As a Flex developer, you can enable users to see your source code when they right click on your application ("View Source"). (To enable this, in Flex Builder, choose Project -> Publish Application Source...).
You Flex application will work well with a Java backend system or PHP backend system. For PHP integration, you'll want to download and use the open soure project AMFPHP. You can read my tutorials on how to integrate Flex and PHP on the Flex Developer Center.
Once you've built your application, you can then deploy the file as you would any other web application (likely to an Apache web server), and end users can interact with that application using the free Flash player. Now, the story would be much better if that Flash player was available on Linux (and if it were open source), but its not, at least not yet (available on Linux that is). However, there is a team of talented engineers working on Flash Player for Linux, and you can follow their progress on their blog. Apparently a beta version of Flash Player 9 for MacTel machines should be out soon, with a beta for Linux sometime later this year.
One of the benefits to web applications for Linux enthousiasts has always been the fact that web applications are not tied to a specific operating system - they simply need a web browser to work. The main problem to this model has been the the client: web applications today cannot replace desktop applications, there are too many limitations: local file access, no vector drawing APIs native in the browser, rich media integration isn't supported, JavaScript execution speed isn't the same as compiled code... Flex applications solve most of these problems (a drawing API is available in the Flash player, it can integrate rich media content easily, and it now has a JIT compiler for better performance), and we hope to have a better solution for local file access when we release Apollo (a beta version is expected later this year).
The development of more advanced web applications will continue to help adoption of operating sytems where the Flash Player is available, including Linux. And yes, some developers are working on an open source Flash player.
No, the story isn't perfect, but I think its pretty good. The Flex SDK includes the source code to Flex components, you can build and debug Flex applications on Linux, those applications can interact with an open source backend system (PHP), and end users can interact with those applications at no cost (and in a little while on a free operating system).
BTW: I'm always interested in your feedback on how Adobe can contribute to the open source community.
technorati tags:opensource, php, adobe, ria, flex, web2.0, flash, eclipse, flexbuilder
Blogged with Flock
June 28, 2006
Flex 2 and Future Web Application Development
Flex 2 has been released (CNET coverage here, TechCrunch coverage, Digg the story). You can buy it from the Adobe online store for $499, or $749 with the charting components included. The SDK for Flex is free, as in beer, and there's a free version for Flex Data Services included as well.
This release marks an important milestone for Adobe, as my colleague Bill McCoy has discussed in his blog. Some great web applications have been built with Ajax, but increasingly a number of them are using Flash in areas that the browser cannot handle: rich media integration (You Tube, Google Video and others use Flash to stream video), saving data locally (using the Flash Shared Object), applications that demand higher performance from the client (Flash code is compiled as opposed to Ajax / HTML code). Google Finance is a great example of using Flex and Ajax together, and using Flash where it makes sense (rich graphics drawn on the client).
Yes, you can do some very cool things with Flex right now. However, future development looks even brighter from an Adobe perspective. Apollo will provide additional APIs to web applications that will allow them to integrate into the operating system - users will launch web applications just as they would a regular desktop application (with icons on the desktop / dock / taskbar), the ability to save large amounts of data on the local machine (not limited to the 100K default for the shared object), and perhaps most importantly the ability to develop an application once and then have it run on multiple operating systems (we've committed to making Apollo cross platform). Watch a developer week session about Apollo.
Take that view of the future along with the ability to create mobile applications that run on FlashLite using the same set of technologies. Plus, unlike other languages, building a mobile application for FlashLite will work across a variety of devices - anywhere that the FlashLite player is installed. (Did you miss the announcement of the FlashLite deal with Verizon?) Can you see why JD was so excited about this deal earlier this year?
Here are a few other links about the release:
The source code derived from the Eclipse code is available for download.
A version of Flash Player 9 for Linux is underway. Follow the Penguin.swf blog for more information.
Flex.org is a new site that launched today as well, with resources for the community related to Flex.
FlexCoders.net has a list of Flex developers, if you're interested in building out a Flex project and need some help. If you need work, register there.
For historical Flash designers / developers, Adobe Labs now has a preview of Flash Professional 9 with ActionScript 3.
technorati tags:adobe, flex, ria, ajax, opensource, flashlite, mobile, apollo
Blogged with Flock
June 23, 2006
Sys-Con Announces Real-World Flex Seminar in August
Sys-Con will be hosting and producing a day-long event about Adobe Flex. The event will take place in New York on August 14th. If you're interested in Flex or building applications with Flex, this is definitely something that you'll want to attend.
From the webpage, "The list of topics at the Real-World Flex Seminar includes:
Registration for the event is only $395, and includes breakfast, lunch, a 12 hour DVD of the seminar, a t-shirt, a laptop back-pack and future access to on-demand video presentations of the seminar.
technorati tags:flex, ajax, seminar, adobe, actionscript, coldfusion, apollo, mxml
Blogged with Flock
May 10, 2006
E-Business Application's Demo of Flex / Ajax Bridge
Alexei from e-Business Applications has posted a screencast that shows off integrating Flex with their Ajax based data grid. They're using Flex for the charting component, while the grid is populated with data from an Ajax call. Cool use of Flex and Ajax integration using the Flex / Ajax bridge.
April 7, 2006
Presenting Flex and PHP to Boston PHP UG
For those of you near or in the Boston area, on June 1st I'll be presenting Adobe Flex and how it integrates with a PHP backend using AMFPHP to the Boston PHP User Group. I'll show off Adobe Flex Builder, the integration with a backend PHP system with AMFPHP, as well as demo the Adobe Flex / AJAX bridge. If I have time, I'll show off Adobe Flex Data Services as well. I had a great meeting with Mark Withington, who runs the group, yesterday at Linux World. I'm looking forward to the talk. If you're in the area, drop by. More details on the Boston PHP UG website.