Having problem adding two classes to a div element

Tell us what’s happening:
Describe your issue in detail here.
I have a problem facing at this stage of the challenge, the step tells me I need to add a class one to the first marker div element, and when I do it, it doesn’t work, this div element already has one class that is marker, but I need to add a second class one. can anyone guide me what I am missing?

  **Your code so far**
/* file: index.html */
<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Colored Markers</title>
  <link rel="stylesheet" type="text/css" href="styles.css">
</head>
<body>
  <h1>CSS Color Markers</h1>
  <div class="container">
    <div class="marker">
    </div>
    <div class="marker">
    </div>
    <div class="marker">
    </div>
  </div>
</body>
</html>
/* file: styles.css */
h1 {
text-align: center;
}

.marker {
width: 200px;
height: 25px;
background-color: red;
margin: 10px auto;
}

  **Your browser information:**

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

Challenge: Step 16

Link to the challenge:

1 Like

you can assign multiple class values in the same attribute class separated by a space

3 Likes

Also, an update has been made to this lesson to show an example of how to add multiple classes to html elements.

That change should be live soon

2 Likes

thank you, found that right after I posted this, but I just left the question so it could help others as well.

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