Last active
January 4, 2016 07:59
-
-
Save plutochill/8592292 to your computer and use it in GitHub Desktop.
PNG Hack/Fix for IE 6
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*For CSS background-images*/ | |
.yourselector { | |
width:200px; | |
height:100px; | |
background: url(/folder/yourimage.png) no-repeat; | |
_background:none; | |
_filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(src='/folder/yourimage.png',sizingMethod='crop'); | |
} | |
/*For inline HTML images*/ | |
img, .png { | |
background-image: expression( | |
this.runtimeStyle.backgroundImage = "none", | |
this.runtimeStyle.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='" + this.src + "', sizingMethod='image')", | |
this.src = "/img/blank.gif" | |
) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment