One By One Design

Two Flash Website Generation Tools

For those of you who regularly use swfobject, expressInstall, and swffit (formerly “fitflash”) for your Flash websites/applications, I just developed a couple tools that will make you love me.

The first is just a simple html template that can be used with Flash. Download the template here and extract the html file to your HTML directory (on a Windows machine that’s at C:\Documents and Settings\[USER]\Local Settings\Application Data\Adobe\Flash CS3\en\Configuration\HTML – mac users are on their own). Now open Flash and go to the HTML publish settings. In the “Template” drop down box, you’ll find one named “SWFObject, SWFfit, and ExpressInstall”. Select that and you’re good to go. A word of advice though – to include a document title and a description in your generated html, in Flash you’ll need to go to “Modify” -> “Document” and set the title and description there. The swffit dimensions will be set according to the dimensions of the .swf file. Long story short, you will generate a .html file that looks like the one below straight out of Flash.

		This is my title.
Get Adobe Flash player
You need Flash Player 9 and javascript enabled to see the content of this site.

Of course the trouble with that is, you will still have to manually add the swfobject.js, swffit.js, and expressInstall.swf files yourself, and that’s a lot of extra work.

So, for the ultimate in laziness convenience, I came up with the OBO Site GatherAIR (please, god, someone post a comment suggesting a better name – I write code, not copy). As the horrible name implies, the Site GatherAIR is a desktop AIR application that makes your life 100% easier. All you have to do is specify an output directory, then drag and drop a .swf file into the hard-to-miss target area and all javascript, html, and .swf files will be automagically added to the specified directory. The application also allows you to customize the html file to a limited degree by adding a title, author, some keywords, a background color, a description, and whether or not to allow fullscreen or the Flash context menu. None of that html stuff is required though. If left blank, the title will be the same as the name of the .swf file, the background will be a greyish blue (similar to a default Flex background), the fullscreen and menu will both be false and everything else will be left blank. Essentially speaking, you’ll get the same html as posted above.

Here’s what it looks like:

OBO Site GatherAIR screenshot.

The application comes packaged with swfobject version 2.1, swffit version 1.0 and expressInstall whatever version it is. Hopefully, the authors of those fine products aren’t upset by my little redistribution, but they are open source projects and I give the authors (Geoff Stearns, Miller Medeiros, and whoever the hell originally created expressInstall) full credit. Should you use this, though, and need to update the files, navigate to the installation directory, look for a directory named “includes” and replace the three files found there (making sure they still have the same file names!).

This project also makes use of Ben Stucki’s “metaphile” – a nice (though painful to use) package for reading header/metadata info from various file formats.

The current version of OBO Site GatherAIR, 0.5, can be downloaded here.

Looking towards that orgiastic future I believe in, some things I would definitely like to add to this application: more user controlled html settings, more output templates, and, really, the ability for users to add custom templates of their own. But all that takes time, and who has that these days?

Of course for a little bit of bread, I could be easily persuaded to make some time to custom tailor something similar for an individual or company. I’m just sayin’…

Posted by

Post a comment

Your email address will not be published. Required fields are marked *