What is wrong with this code?

Tell us what’s happening:
what is wrong with this code?

Your code so far


<style>
  .red-text {
    color: #ff0000;
  }
  .green-text {
    color: #008000;
  }
  .dodger-blue-text {
    color: #1E90FF;
  }
  .orange-text {
    color: #ffa500;
  }
</style>

<h1 class="red-text">I am red!</h1>

<h1 class="green-text">I am green!</h1>

<h1 class="dodger-blue-text">I am dodger blue!</h1>

<h1 class="orange-text">I am orange!</h1>

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/68.0.3440.106 Safari/537.36.

Link to the challenge:
https://learn.freecodecamp.org/responsive-web-design/basic-css/use-hex-code-to-mix-colors

my guess is it doesnt want you to use hex codes but the color itself
so instead of color: #000000 use color: green;

Wrong hex-code for green.
see the left pane on challenge.

I see the problem now. Thanks

Here is the correct code
In this you have to replace the color name with their HEX code you can see in the below code which i correct.

.red-text { color: #FF0000; } .green-text { color: #00FF00; } .dodger-blue-text { color: #1E90FF; } .orange-text { color: #FFA500; }

I am red!

I am green!

I am dodger blue!

I am orange!

1 Like