开发者

PNG color issues

开发者 https://www.devze.com 2023-01-31 03:33 出处:网络
I have an image with a background color and I\'m putting that in a div with the same background color.For some reason I cant save this image as a PNG and have the image bg color show the same as the b

I have an image with a background color and I'm putting that in a div with the same background color. For some reason I cant save this image as a PNG and have the image bg color show the same as the bg color in the div across all browsers on all operating systems.

At first it looked fine on Windows/Mac in every browser except IE. So I tried using tweakPNG to remove the color profile and gamma开发者_JAVA技巧 properties and that seemed to fix for IE but now I have the issue in Firefox on Linux for some reason?

Any ideas/insight? Thanks


You didn't specify which version(s) of IE you had problems with, but older versions of IE are known to have bugs and missing features with PNGs.

In particular IE6 doesn't support PNG transparency at all, and IE7 has bugs with it.

There are a number of Javascript-based hacks available to fix this issue in IE. Here's a link to one of them: http://www.twinhelix.com/css/iepngfix/ - but there are a number of others that do the same job.

If you're having a problem with Firefox after running the graphic through tweakPNG, my guess would be that tweakPNG has corrupted the graphic slightly.

My suggestion would be to try going back to the original version of the graphic, and try out the hack I linked above in IE.


You must remove the GAMA filter on your PNG.

This soft make it quickly and easily.

  1. Import your PNG
  2. Right clic on gAMA
  3. Delete
  4. Save

Tutorial here

0

精彩评论

暂无评论...
验证码 换一张
取 消