G
G
GaserV2015-09-01 21:38:03
Sass
GaserV, 2015-09-01 21:38:03

Why is bgcolor not shared with bgimage?

Tell. Why doesn't shading work on the picture?

#header
  height: 100%
  width: 100%
  position: absolute
  display: table
  z-index: 1
  background: url(../img/header-bg.jpg) rgba(0,0,0,0.6)
  background-size: cover

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Denis Bochkov, 2015-09-02
@DENCREAT

rgba(0,0,0,0.6) - here the fourth parameter adjusts the alpha channel for the color (black in this case). Your image is overlaid on a black background. And there already adjust, do not adjust the transparency for the color because of the picture you will not see anything. To darken the background image, use the second semi-transparent image.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question