Transparency in CSS

Let's consider all over again every possible effects of a transparency which will be visible only to users Internet Explorer.

For example, there is at you a certain picture which contains in yours html to page. The given picture without participation of any graphic packages, can be modified using effect of a transparency. Internet Explorer possesses the ample opportunities in this area. We shall consider all possible{probable} examples.



For nachala pazberjomsja how correctly to introduce a code css in html page that it was possible to observe required effect. If you want to apply effect to some certain pictures (actually it is possible to make transparent not only a picture, but also a background) in the best way to introduce style in a tag of a picture.



<img border = "0" src = "src/logo.png" width = "100" height = "97" style = " filter:alpha (opacity=30); "/>


opacity is and there is that parameter which creates effect of a transparency.

In the resulted example which is fair only for IE, opacity can accept values from 0 up to 100. If value is close to zero the picture is maximum transparent and on the contrary at increase in value of the given parameter the picture gets an initial kind.


IE

So for creation of effect of a transparency in IE you can use following css codes:



filter:alpha (opacity=30);

/* Syntax IE4.0*/

filter:progid:DXImageTransform. Microsoft. Alpha (opacity=50);

/* Syntax IE5.5 + (is preferable) */


Moreover at use IE it is possible to receive beautiful effects gradientnogo clarification. (in other browsers does not work).



filter:alpha (opacity=80, style=0);

filter:alpha (opacity=80, style=1);

filter:alpha (opacity=80, style=2);

filter:alpha (opacity=80, style=3);


Depending on parameter style it is possible to achieve various gradientnykh osvetlenij.


Let's consider an opportunity of clarification of figure at the left on the right.



filter: alpha (startx=0, style=1);

filter: alpha (startx=20, style=1);

filter: alpha (startx=60, style=1);

filter: alpha (startx=100, style=1);


Depending on value startx it is possible to observe a various degree osvetljonnosti. If value is close to zero the picture is maximum transparent, and, on the contrary, at increase in value of the given parameter the picture gets an initial kind.


One more way of clarification, but with sharper borders is possible{probable}.



filter: alpha (finishx=0, style=1);

filter: alpha (finishx=20, style=1);

filter: alpha (finishx=60, style=1);

filter: alpha (finishx=100, style=1);



As it is possible to see borders so sharp, that a part of a picture thus it is not visible and at all.


And at last, an example of right-hand illumination.



filter: alpha (opacity=0, finishopacity=10, style=1);

filter: alpha (opacity=0, finishopacity=20, style=1);

filter: alpha (opacity=0, finishopacity=60, style=1);

filter: alpha (opacity=0, finishopacity=100, style=1);


Depending on value finishopacity it is possible to observe a various degree osvetljonnosti. If value is close to zero the picture is maximum transparent, and, on the contrary, at increase in value of the given parameter the picture gets an initial kind.