HTML Introduction to HTML and CSS Make It Beautiful With CSS Adding a Style to several Elements using Class

Duaa Saif
PRO
Duaa Saif
Pro Student 894 Points

Add a class called social links to anchor tag

<a href="#">Follow me on Twitter!</a>

index.html
<!doctype html>
<html>
  <head>
    <title>List Example</title>
    <link rel="stylesheet" href="styles.css">
  </head>
  <body>

    <a href="#">Follow me on Twitter!</a>
    <a href="#">Send me an Email!</a>

  </body>
</html>
styles.css

1 Answer

Liam Clarke
MOD
Liam Clarke
Treehouse Moderator 18,902 Points

Hi Duaa

it is asking you to add classes to each of the anchor tags.

No styling is done yet.

Classes are one of the ways for styling the HTML with CSS

In order to style the social links represented by anchor tags in HTML, we add a class called "social-links" to them

<!doctype html>
<html>
  <head>
    <title>List Example</title>
    <link rel="stylesheet" href="styles.css">
  </head>
  <body>

    <a class="social-links" href="#">Follow me on Twitter!</a>
    <a class="social-links" href="#">Send me an Email!</a>

  </body>
</html>