Style Multiple Elements with a CSS Class Issues

Guys, I’m having trouble understanding what I’m supposed to do here exactly. I’m completely new to coding, and trying to teach my younger brother as we go along. I felt that the tutorials were going well up until this point, and this just doesn’t seem to be explained very well. Could someone tell me what I’m styling with the multiple elements, and how adding

class=“red-text”>

before the actual content of my paragraph element doesn’t work? I’m not understanding this completely, and the “Get a Hint” option did not explain anything at all to me.

Thank you!

Your code so far

<style>
  .red-text {
    color: red;
  }
</style>

<h2 class="red-text">CatPhotoApp</h2>

<p> class="red-text">Kitty ipsum dolor sit amet, shed everywhere shed everywhere stretching attack your ankles chase the red dot, hairball run catnip eat the grass sniff</p>

Your browser information:

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

Link to the challenge:
https://www.freecodecamp.org/challenges/style-multiple-elements-with-a-css-class

You just have a slight typo in your code. The class declaration should be in the <p> tag.

It would look like this:

<p class="red-text">Kitty ipsum dolor sit amet, shed everywhere shed everywhere stretching attack your ankles chase the red dot, hairball run catnip eat the grass sniff</p>

1 Like