Posted By


DeadLy on 01/18/08

Tagged


Statistics


Viewed 1016 times
Favorited by 2 user(s)

IE PNG FIX. CSS Solution


/ Published in: CSS
Save to your folder(s)



Copy this code and paste it in your HTML
  1. * html img,
  2. * html .png{
  3. azimuth: expression(
  4.   this.pngSet?this.pngSet=true:(this.nodeName == "IMG" && this.src.toLowerCase().indexOf('.png')>-1?(this.runtimeStyle.backgroundImage = "none",
  5. this.runtimeStyle.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='" + this.src + "', sizingMethod='image')",
  6. this.src = "/images/transparent.gif"):(this.origBg = this.origBg? this.origBg :this.currentStyle.backgroundImage.toString().replace('url("','').replace('")',''),
  7. this.runtimeStyle.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='" + this.origBg + "', sizingMethod='crop')",
  8. this.runtimeStyle.backgroundImage = "none")),this.pngSet=true
  9.  
  10. );
  11. }

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.