Web Developer Musings

In favour of Flash, Part 1

23 May 2009, 14:13

Over the last two years Javascript has gained in popularity and taken a large market share away from Adobe Flash in delivering online multimedia and interactive applications. I believe the main reasons for this are developers becoming more concerned with accessibility and simplification of implementing Javascript.

On the first issue I am unconvinced there is a winner. Though Flash can be made in an accessible manner supporting tab and access keys it isn't a suitable tool for delivering a universally usable website or widget. Flash is mainly used for creating interactions that simply do not suit this kind of navigation, or at least developing a Flash project supporting keyboard focus and mouse would take too much time for the small audience gain it may or may not receive. Conversely, forcing the majority of mouse users on to the keyboard to interact with your website is also highly likely to confuse rather than captivate the audience.

As good or bad as Flash may be for accessibility this does not grant my automatic support for Javascript. As most good designers and developers know, a website relying on Javascript for core functions must be built using progressive enhancement. The common adoption of Javascript frameworks has meant there are thousands of plug-ins, widgets and mash-ups in widespread use that lack of any degradation - though this may be relief for users who do not want to know what you're writing on Twitter anyway.

OK, this is all a bit pre-2004 and Javascript access is normal for over 99% of Internet users but there is a much more important question: 'But what does it look like in Internet Explorer/Opera/Safari/Chrome and on my mobile phone/console/MP3 player?'. Though many JS frameworks are well tested and provide a shortcut for providing cross-browser compatible code there are very few areas where behaviour truly is, especially when mobile. Flash entirely side-steps this, the player is available on almost anything and will render and work in the same way almost all of the time. Flash also negates the need to worry about end users having support for various media other than a version of Flash Player installed equal or above the one you have published your work with.

I do not think there is a winner when accessibility is primary concern. Creating accessible Javascript or Flash is difficult, though the former requires full understanding of many programming languages and how they all work together; HTML, CSS, Javascript, browser compatibility and at least the basics of a dynamic server-side language. Flash however requires an understanding of only one.

Comments

#1 Patrick 392 days ago.

I find it kind of funny that a self-proclaimed web dev uses a clonky CMS instead of just making a quick (and more importantly, light) back-end. But that's beside the point.

I don't really see why you're comparing Flash to JavaScript and then saying you have to choose. They serve two completely different purposes. The only similarity between the two is that you should never assume a user has them installed. Other than that, the similarities end and the differences begin.

I'd just like to touch on two points you argued:

1. JavaScript requires progressive enhancement.
-- Yes, it does. As does CSS. You should always start with a basic semantic layer, add a presentational layer, and then a behavioral layer. If your website doesn't work or doesn't make sense when I turn page styles off, it's a *bad website*. And since a lot of users are in the mobile phone/text-only/screen-reader category, this should be priority over everything else.

2. JavaScript doesn't look the same in every browser.
-- Which is why you need to make it look the same. This also goes for HTML and CSS. Developing for the web is programming first, pretty pictures second. If it doesn't work in IE, then make it work in IE.

I like Flash for easy-to-use media players. It's wonderful if I want to make a playlist online or if I want to start a movie website. But there's no point in arguing Flash vs JavaScript because it was never about Flash vs Javascript; it was about Flash vs good programming.

#2 Matt 371 days ago.

You're right to point out CSS as a presentational layer and there is an issue of some websites ignoring semantic markup, but fortunately I do think it is less of a readability issue.

When writing this post I had interactive, animated websites in my mind. There are many websites - such as portfolios - popping up with items fading in and out, flashing and loading content dynamically. It is these that can have huge issues and I was considering.

Leave a comment