views:

211

answers:

1

IE6 and IE7 don't scale images nicely in web pages when the images are scaled with css width/height or attribute width/height. I am not sure which algorithm it uses by default, but it's not good.

Scaled images display aliasing artifacts when scaled in these browsers.

+8  A: 

Fortunately there's a way to force IE7 to use the bicubic scaling algorithm (which looks very nice) with a simple css rule:

img { -ms-interpolation-mode: bicubic; }

The results are great, and it can be done site-wide with this single rule.

For IE6 you're out of luck as far as I know.

apinstein
I don't get what's offensive about this. Asking and answering your own question is a practice that's encouraged on SO. What would you prefer someone do, keep their knowledge to themselves?
tvanfosson
Only works on IE7+, not 6.
bobince
apinstein
Also I'll point out that I originally got this tip from Joel Splosky's blog, but I think it deserves to be on Stack Overflow!
apinstein