Can you help me what this is mean? I don't understand what to do? please help me

Tell us what’s happening:
Describe your issue in detail here.

  **Your code so far**

<style>
:root {
  --red-color: red;
}
.red-box {

  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 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/92.0.4515.131 Safari/537.36 Edg/92.0.902.73

Challenge: Improve Compatibility with Browser Fallbacks

Link to the challenge:

Solution:

<style>
  :root {
    --red-color: red;
  }

  .red-box {
    background: red; // Add this line here. It acts as a browser fallback
    background: var(--red-color);
    height: 200px;
    wdth:200px;

  }

</style>

<div class="red-box"></div>
1 Like

not working Sorry :cry: :cry: :cry:

@Tynael code works for me when I try it.

just above the


like this?

If the code is correct but not working for you check to see if your web browser has any add blockers or dark modes enabled as these will cause problems for the tests.


I turned to light mode too but still not working

On the latest image I see you have put the background:red; below the background:var(--red-color);
You need to swap them around so background:red; is above.
If it doesn’t work do you have a different browser you could try it on?

thanks, I tried on another browser and that worked

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.