Getting Data into Your Flash Files – A Million Ways Can’t Be Wrong?


My previous post about my thoughts on the current Flash climate was apparently just a small slice of this somewhat larger growing sentiment. The Flash community is definitely changing. These posts here and here seem to prove it to me. Lots of negativity for what should be a positive thing: A member of the community making something unlike what was already out there and sharing it with anyone who wanted to try it. These types of efforts make things simpler for users by providing options. Flexibility is one of the major draws for many starting Flash designers in my experience. I teach and work with beginning students building their first timelines and parsing their first XML. I know that the multitudes of options can sometimes get a bit confusing, but do provide ways to ease users into achieving their goals using a method they feel comfortable with.

The SWX data exchange format was created by Aral Balkan and posted for download. It seems like the community was a bit split on the value added by it. It’s open source software, why worry about things like this? I personally thought it looks promising, if for no other reason than it looks pretty dead simple and gives us yet another way to get data into our Flash. Why is this a godd ting? Flashvars and TXT is antiquated and not scalable. Using middleware scripts is oftentimes annoying. Loading and parsing XML can be a pain. Remoting isn’t as easy as it should be, IMHO (Although the recent Lullabot podcast covering the AMFPHP and Services modules for Drupal sounded very promising). And the reasons go on and on. SWX looks simple to integrate with a team that is split between Flash and PHP that hasn’t quite gotten on the AS3 train yet.

This library comes about at a little bit of a strange coincidental moment for me. I have recently begun to reevaluate the way I am bringing information into my movies. I’m still using XML(sometimes statically created, sometimes server side generated), but the way I am handling it is becoming tedious. I too, am long tired of the firstChild, etc. monotony. In fact, that is really the reason I laid off Flash5′s XML and waited for the MX improvements to abandon the LoadVariables() from a .txt name-value pair/query string in the placement code insanity I had been subjecting myself to since Flash 4. I use the method Darron Schall had on his blog a year ago most of the time. But I have to admit, I’m lazy… I wanted something easier.

This led me to the CasaFramework. It really looks good to me. The xmlToObject and objectToXml methods especially. I also like the framework’s timer and inactivity stuff too. I do build a kiosk for a museum or tradeshow everyonce in a while and they always need to be reset to the splash after a period of inactivity. I’m sure that some might say some of this isn’t done the right way (AS3), but it works. I’m just beginning working with it and can see that like the relationship between McTween and I, this might be the beginning of a beautiful friendship.

I see nothing wrong with using code that gets the job done quicker and allows you to do it the way you want to do it, as long as its not hampering the performance of the application you are building. These types of choices allow you to get more done faster, and build bigger, better, more engaging experiences for your users. These bigger better things happen because people share. Posts on blogs, code snippets, an mxp, an entire framework, etc. The sharing and collaborative environment is what really makes working in Flash what it is, fun. Going back to my days as a regular at Were-Here.com, the community was always positive. Lets just hope we haven’t traded that for packages, strong typing and an overall less flexible language. Maybe staying at AS2 isn’t so bad if that means we can keep that good community vibe going on.

Now, this post isn’t directed specifically at any one developer or group of developers for that matter. I certainly don’t want to step in the crosfire that was going on the other day over this topic. It was just purely coincidental that this blog thread occurred, and I had recently written some thoughts that echoed the perspective offered by Mr. Balkan. Now, take my opinions written above just as that, opinions. I am not a Computer Scientist. I am a web and Flash designer/developer who just so happens to have to build a lot of things quickly, for what is usually a small to medium budget and a very tight schedule. Creativity, flexibility and ease of development are of paramount importance to me. A heavy or large architecture oftentimes just isn’t practical on a project with a two week turnaround.

Flex goes a long way to help the developer make some right choices for application development, certainly. But, what percentage of Flash developers are moving to Flex though? Judging by my friends and coworkers it’s a bit niche, but growing. Therefore, I believe these quick, light methods for GTD in Flash are still needed. Flashvars, query strings, text files, xml.load, AMFPHP, SWX, frameworks like Casa, all have their place. There are about a million and one ways to do just about anything in Flash and I wouldn’t want it any other way.

Posted on


3 comments

  1. Theo Apr 1

    Don’t confuse criticism and negativity. Without criticism there is no progress. If the only comments to new ideas are by those who like them there is no way of knowing good from bad.

  2. Theo Apr 1

    Don’t confuse criticism and negativity. Without criticism there is no going forward. If the only people commenting on new ideas where those who liked it there would be no way of telling the good from the bad.

  3. Chad Apr 1

    Theo, while that is certainly true, criticism generally mentions both the positive and the negative aspects of a piece. This is where the phrase “constructive criticism” comes in. Also, lets not forget that my true focus of this post wasn’t about the SWX debate, but rather the larger issue of narrowing of flexibility being a bad thing for Flash development in general.

Leave a reply