How can I control the visibility level of a div and view it?

Can I control the visibility of some div on my website and make it accessible only with CSS? In a flash, this happened while controlling what is called Alfa, so I wonder if such a thing exists in CSS!

Edition 001

Can I control the opacity of only the background div? So the text in the div will not execute?

+3
source share
4 answers

http://www.quirksmode.org/css/opacity.html

.opaque1 {  // for all other browsers
    opacity: .5;
}

.opaque2 {  // for IE5-7
    filter: alpha(opacity=50);
}

.opaque3 {  // for IE8
    -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=50)";
}
+2
source

You can use opacity in CSS

.transparent_class {
 opacity: 0.5;
}

, Internet Explorer, , IE:

.opaque1 { // for all other browsers
 opacity: .5;
}

.opaque2 { // for IE5-7
 filter: alpha(opacity=50);
}

.opaque3 { // for IE8
 -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=50)";
}

+3

Another way to make only a transparent background is to use transparent png as the background image, and then use this jQuery fix for IE's special snowflake. As far as I know, this works in all browsers.

+2
source

Here is a good link talking about CSS navigation. Hope this will be helpful:

http://www.webcredible.co.uk/user-friendly-resources/css/css-navigation-menu.shtml

+1
source

Source: https://habr.com/ru/post/1730023/


All Articles