HTML Introduction to HTML and CSS Make It Beautiful With CSS Test: Styling by Element and Class

James Ming
James Ming
341 Points

how to add a class attribute to a paragraph

How do I add a class attribute to a paragraph in html??

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

    <p> My amazing website</p>

  </body>
</html>
styles.css

1 Answer

Dehn Hunsworth
Dehn Hunsworth
7,189 Points
<p class="<insert class name>">This is a Paragraph </p>