How to fix png image issue in IE6?

1.1k Views Asked by At

I know there are many ways available on internet, I found one with using iepngfix , but to resolve this issue i need to specify width and height to each png image and its too time consuming process for me. Because i have 1000's of png images in my project, Is there any way to resolve this issue without specifying width and height to image tag,

My image tag is :

<img src="myPngImage.png" width="120" height="100" />
3

There are 3 best solutions below

1
Halim Qarroum On

You might want to look at CSSPie, I use it personally and so far it works great. I didn't test for images transparency in IE6 but seems to be well-supported http://css3pie.com/documentation/supported-css3-features/#pie-png-fix.

0
ScottS On

If you must support IE6, then I recommend using something like jquery's capabilities (which will auto detect the width/height of images).

0
ShibinRagh On
<!--[if IE 6]>
      <script src="js/DD_belatedPNG_0.0.8a-min.js" type="text/javascript"></script>
      <script type="text/javascript">
            DD_belatedPNG.fix('img,div,ul,li,li a,a,input,p,blockquote,span,h1,h2,h3');
      </script>
      <![endif]-->

download code from here

http://trac.symfony-project.org/browser/plugins/pkToolkitPlugin/trunk/web/js/DD_belatedPNG_0.0.8a-min.js?rev=20453

or

customize-your-blogger.googlecode.com/files/DD_belatedPNG_0.0.8a-min.js