Using addClass with IE pngfix

Using addClass with IE pngfix

Hi all,

I use the UniPngFix script on my site in order to make IE6 render transparent PNGs.
It uses a classic alphaImageLoader MS filter (and is definitly the best IMO).

This script requires an additionnal class on targeted elements. Problem is I don't want to spoil my code by hard coding these classes.

So I try to use

$("div").addClass("unitPng");

in an conditional comment within the script but it does not work. In or outside the comment, whatever the position on the page.

I'm a newbie in javacript, I assume the class is added AFTER the script is triggered.

Do you know a workaround ? Or any other way to add a class in the code ?

Thanks a lot !