HTML5 Zone is brought to you in partnership with:

I live in the sometimes sunny Brighton (it's in the south of the UK, for those across the pond). The south coast is definitely my favourite place to be, but I spent some time on the outskirts of London whilst at University. I'm starting to focus on my own company Left Logic. It's a web development company with strong focus in usability, accessibility, clean design and powerful bespoke applications. Remy is a DZone MVB and is not an employee of DZone and has posted 53 posts at DZone. You can read more from them at their website. View Full User Profile

HTML5 vs Flash

  • submit to reddit

First of all I wanted to make the title of this post "HTML5 and Flash", but I know it's going to bait more readers if I say versus. I should state for the record that for the foreseeable future I think Flash has a valid place on the web, and I don't personally see it as an us and them web.

Stephen Shankland, writer for CNET News got in touch and asked me to comment on an article he was writing, posing me the questions in this post. Unfortunately my reply got to him to late and he had to go to post without my answers, but I thought that it would be worthwhile sharing my views via my own blog instead.

How far is HTML (and SVG and CSS and WebGL and JavaScript) to reproducing what Flash can do today?

HTML, SVG, CSS and JavaScript are very far along to replacing a lot of what I see Flash doing today - but it should be noted my browsing style is general usage, rather than gaming or interactive videos - which Flash is good at.

WebGL is very much at an early stage in it's development, only really (currently) appearing in the nightly builds of Webkit and Firefox, equally I've seen videos from Mozilla putting WebGL on to a Nokia device with no optimisation and it being able to render pretty well.

There's lots of examples of apps and effects that have been achieve using Flash in the first decade of this century, but today we can build these using Open Web technologies. This ranges from the simple image galleries to full fledged word processors. Adobe released Buzzword which relies on Flash, but on the other side we have Google Docs which relies entirely on the Open Web.

Would you like to see Flash replaced by HTML?

I personally don't think HTML will replace Flash. I think HTML5 and the Open Web will replace Flash where Flash has been used as a stopgap. sIFR is used to bring "custom" fonts to the browser, but now we have really good support for native custom fonts via the CSS fonts module, and products like TypeKit and FontDeck are making it easy for web authors to include those custom fonts without the need of Flash.

The native video element will (eventually) allow us to drop using Flash for video. Flash has done an awesome job of pulling the braces up on browsers for the last decade, and we've needed it, but Flash is so much more than just video or font rendering. I think the smart developers aren't won't be worried about native browser functionality making Flash redundant for noddy tasks, no doubt they'll be thankful to not have to build another video player.

As much as I'd like to see Open Web technology do everything, I still think we're a long way off HTML being able to able to natively replace applications such as Aviary and games like Bow Street Runner.

Equally, as I mentioned before SVG is one technology that has come along, and with the help of the svgweb JavaScript library, SVG works in IE. This library of course gets IE to support SVG via Flash. It translate the SVG markup on to a Flash canvas proving that Flash still has a place on the web as a bridging technology as well as it's intended use.

How serious do you think the H.264/Ogg Theora matter is with the HTML5 video codec?

It's hard to say. Personally it doesn't make much difference to me if I have to encode once, twice or three times. Encoding is a background task so I set my converter off when I produce my screencasts and after an arbitrary amount of time I'll have some files to upload - obviously if you have masses of video to encode the disk usage is going to be a possible issue for you.

The problem lies with patents, which is why Firefox and Opera won't implement H.264 - but the politics and patents are for smarter people than me. There's also the fear that we as content producers could be liable for license costs to the patent owners of H.264.

On the other hand, the company that own the patent for H.264 has elected not to collect royalties until 2016 - when they may again choose not to collect royalties. Flash developers have been using H.264 for some time already and there hasn't been any retribution for them, but for now I'll be producing both H.264 and Ogg Theora encoded content.

I'll be watching this topic closely to see how browsers deal with the two codecs.

As HTML etc. gets what Flash has today, do you think Flash will move upstream and remain relevant, become optional, or what?

I think two things will happen. Firstly I do think that Flash will move (or remain in some cases) upstream, and continue to push what's capable within the browser. Gaming is a great example of an arena that Flash excels at. The second thing I think we'll see is Flash developers taking the progressive enhancement approach to applications, relying more on HTML based solutions and enhancing upwards using Flash - Jeffrey Zeldman posted a great article recently suggestion exactly that.

How difficult is it for a Web developer today to use the fragmented Open Web standards vs. the more consistent Flash?

I don't think it's too hard at at all, but it really depends on what technology you choose. Web Storage has pretty solid support in the latest browsers (if not the nightly builds), but it's relatively easy to patch missing support just using JavaScript which would map sessionStorage to the hack and localStorage to cookies.

Geolocation can be detected and made use of if it's available, whilst those without the functionality can still map their position using something like Google Maps or a text field, thus taking a progressive enhancement approach.

Offline applications on the other hand can't be achieved if the technology isn't available - so it really depends on the application, it's use and whether you have a specific platform in mind for deployment (which generally I wouldn't encourage, but we know it happens).

Flash developers definitely have an easier time when it comes to deployment environment - in fact I've met a number of Flash developers now that said they made the shift from JavaScript and HTML years ago to Flash because of the appeal of a single environment: the Flash runtime.

Anything else on the subject?

As I said at the start of this post, I don't see this as an us and them, Open Web and Flash. I do see HTML5 plugging the areas that have been held up by Flash for the first decade of this century, and there are other areas that HTML5 supports that Flash doesn't - but Flash could even make use of, such as Offline Applications.

It's an exciting time on the web again where browsers are implementing features that make it an even more powerful platform to develop on. I for one, am keen as mustard to get building with the new shiny toys they're giving us. Equally, I'm certain Flash will continue to be used to build awesome shit (and probably some not so awesome shit) for a long time yet.


Published at DZone with permission of Remy Sharp, author and DZone MVB.

(Note: Opinions expressed in this article and its replies are the opinions of their respective authors and not those of DZone, Inc.)


Jeroen Wenting replied on Tue, 2010/02/09 - 3:44am

At this time (and for quite some time now) I have a tendency to move away from websites using Flash as they are almost invariably too flashy (no pun intended), looks being considered more important than functionality.
Flash breaks bookmarking, ease of navigating the site, opening individual pieces of information in their own windows or tabs, etc. etc..
Of course all those can be done in html as well, but less easily and therefore are done less often.

Ei Sabai replied on Tue, 2010/02/09 - 7:58pm

I don't think Flash will ever be replaced by HTML but with the introduction of CSS 3 and HTML 5, I'm hoping to see less and less flash websites in the near future.  

Jose Maria Arranz replied on Wed, 2010/02/10 - 4:01am

Equally, as I mentioned before SVG is one technology that has come along, and with the help of the svgweb JavaScript library, SVG works in IE. This library of course gets IE to support SVG via Flash

Yes and no, the main purpose of SVGWeb is to provide SVG to IE, fine, but SVGWeb can run optionally in any other browser providing video and audio capabilities integrated in SVG (for simple drawing native SVG is today a better option).

The most interesting thing of SVGWeb is you DO NOT need to install more plugins because Flash 9 (SVGWeb minimum requirement) is already installed in near 100% of computers.

SVGWeb is promising however is not alone, there are more options for SVG in IE:

* Adobe SVG Viewer v3 and v6 beta

In spite of it has been discontinued by Adobe, ASV is probably the best SVG viewer.

 Recently I've discovered that ASV can manage SVG markup inline on XHTML including DOM dynamic behavior, this feature has been hidden by Adobe for years. See it in action.

* Renesis v1.1

 It was designed as ASV replacement. It is buggy but works.

* Savarese Ssrc

  Basically is a FireFox packaged as an ActiveX plugin for IE, SVG (and XUL) is based on Gecko.

  With some tricks the child SVG document can talk with the HTML container.

* Batik as applet.

  Batik is probably the most complete SVG renderer, unfortunatelly Batik as applet has been largelly ignored by the web community. In ItsNat has been slightly improved and now can be used as a first class SVG plugin.


Islam El Hosary replied on Thu, 2010/02/11 - 1:20am

I hope too to see power Open Web Tools that can make smart UI without need to use flash.

Akhil Reddy replied on Thu, 2012/07/12 - 3:43am

How to play audio sounds?

Oracle plsql Forum

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.