Sean Middleditch » 2005 » June
So the KANAR web site pretty much requires transparency and translucency in order to work properly. For a while, for the links and such, we’d been using 8-bit PNGs in such a way that their transparency pixel worked like a GIF. In fact, we probably should have just used a GIF, but we decided to be purists.
For the new front-page random images, where we went with this fuzzy cool border thing, because hard-edged borders would have looked like crap on the site’s background/layout, we needed to go with 32-bit translucency, which IE just didn’t want to do.
I was aware of the ImageLoader trick for IE, but getting it to work has been a serious pain. We first tried using several JavaScript hacks that changed all PNGs on the site, but it would cause this annoying white flash when the page was loaded. I tried making them hidden by default and only shown after the code was changed, but the white flash still occured. There was also the problem of IE users with JavaScript disabled.
The final solution was to write some PHP code that detected if IE was in use and to write out the HTML to display the image different if IE was found. It now seems to work pretty well. It was a major pain in the ass, but it works.
Well, I have my chainmail now. I went with steel because KANAR doesn’t allow the aluminum, even with bad-back excuses. Going to wear it around the house for a few days and see how bad my back gets. So far, my back is fine, just my shoulders are a little sore from the weight resting on them. Need a gambeson or some kind of padding there, then I’ll be fine, I think.