Improve Compatibility with Browser FallbacksYour .red-box rule should include a fallback with the background set to red immediately before the existing background declaration

Tell us what’s happening:
hello guys can any one help,
trying to set a second background infront of the first one and set it’s color to red

Your .red-box rule should include a fallback with the background set to red immediately before the existing background declaration.

Your code so far


<style>
  :root {
    --red-color: red;
  }
  
  .red-box {
    background: color="red";
    
    background: var(--red-color);
    height: 200px;
    width:200px;
  }
</style>
<div class="red-box"></div>

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36.

background: color="red";

This is not the correct wayy to set a background color.

1 Like

Ok it s real easy, just add

background: red;

above background: var(–red-color,);

1 Like