PHP Programmer’s Of Bangladesh

Transparent PNG Image Problem in Internet Explorer

Posted by: Md. Masud on: June 30, 2007

Internet Explorer is the main thread for Browser Independent web Solution. Everyperson working with Javascript, css and Image fall into this problem. Among them PNG Image Problem is one of them. The transparent image will work in FireFox but not in IE. 

To Solve this you can use the Following Code: (place this code in your HTML Head Tag)

#gohome img { filter:progid:DXImageTransform.Microsoft.Alpha(opacity=0); }
#gohome img { display: inline-block; }
#gohome { filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(src='icon/browser.png'); }

EXAMPLE:
#span_id img { filter:progid:DXImageTransform.Microsoft.Alpha(opacity=0); }
#span_id img { display: inline-block; }
For Multiple img, write the span_id separated by Comma(,):
EXAPMPLE:
#span_id img, span_id2 img, span_id3 img { filter:progid:DXImageTransform.Microsoft.Alpha(opacity=0); }
#span_id img, span_id2 img, span_id3 img { display: inline-block; }

then deine the each image as follows:
EXAPMPLE:

#span_id { filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(src='imgeSource'); }
#span_id2 { filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(src='imgeSource'); }

See the Example in the attachment.

Leave a Reply

Where I was???

I was a PHP/MySQL web application developer in EVOKNOW INC from 1st July, 2006 to 5th Nov, 2007.

Blog Stats

  • 27,390 hits

What is the date?????

June 2007
S S M T W T F
« May   Jul »
 1
2345678
9101112131415
16171819202122
23242526272829
30  

My Links in Del.icio.us

Google Adds