If you're a web developer, chances are you've grown to hate Internet Explorer 6 due to its inconsistencies with respect to CSS, JavaScript, and standards in general. One additional annoyance is IE6's lack of support for PNG transparency.
At my institution, we still have a very large installed base for IE6 (over 70% of our machines), so I cannot get around coding for IE6. I've been able to avoid the issue in the past by just not using PNG images. But at some point, GIFs won't cut it, particularly in the realm of application icons (See Fam Fam Fam Silk icon set).
I have employed two separate approaches to address this problem. The first is a JavaScript "PNG Fix" that the browser will apply to each image on the page. Essentially the JS script will loop through every PNG, applying the "progid:DXImageTransform" function to each and thereby modifying the opacity.
There are several "fixes" written to do this, all very similar in function. The one I like the most is from Daniel McDonald at Project Atomic. Why do I like it? Its simple (only 25 lines of code) and therefore quite fast. If you have a lot of PNG files on your pages, you can sometimes see each file get transformed as the script slow-walks down the page. Speed is of the utmost importance in any web application. Just include the JS file, a "blank.gif" image, and include a couple of lines in your page header, and you're done.
The second approach I've used to tackle PNG transparency issues in IE6 is really an outcome of the first. The Project Atomic fix works great, unless your PNG is part of a CSS element such as a background image.
The real issue at hand is that IE6 doesn't support 24-bit transparency. It does, however, support 8-bit. So why not change your 24-bit PNGs into 8-bit? For an entire application, this could become a huge amount of work for very little value added, hence implementation of the Project Atomic fix. However, for those less common instances of PNGs as background images, I have followed Matthew Capewell's tutorial to transform the 24-bit PNGs into IE6-compatible 8-bit images.
We're stuck with IE6 for at least a few more years (When Microsoft finally stops providing XP to PC makers for new machines), good Web Developers should be able to deal with IE6 rather than just ignore it.
Note: The Project Atomic Fix is actually in-use on this site, in case you were wondering.







