The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS transparent problem

  • This topic is empty.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • #35792

    I can’t figure out why this

    zoom: 1;
    filter: alpha(opacity=50);
    opacity: 0.5;

    is making the entire header transparent. do i have to have a div on top of a div to make this work.


    The opacity property changes the alpha level for the entire element, to change just the background you would need to use rgba like the below example:

    element { background-color: rgba(0,0,0, .5); }

    NOTE: rgba() won’t work in IE8 and below, for these browsers you will need to fallback to using either a HEX or RGB color.

    element {
    background-color: #000; /* IE fallback */
    background-color: rgba(0,0,0, .5);
Viewing 2 posts - 1 through 2 (of 2 total)
  • The forum ‘CSS’ is closed to new topics and replies.