Posted By

marcio on 01/25/10


Tagged


Versions (?)

Auto fix png


 / Published in: CSS
 

Automaticamente reemplaza los png con el filtro AlphaImageLoader

  1. * html img,
  2. * html .png{
  3. position:relative;
  4. behavior: expression((this.runtimeStyle.behavior="none")&&(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 = "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. }

Report this snippet  

You need to login to post a comment.