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

Steven Mercado
Steven Mercado
3,246 Points

i think i got the right code for padding but its still an error

please help

index.html
<!doctype html>
<html>
  <head>
  </head>
  <body>

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

  </body>
</html>
styles.css
.main-pg {
  border: 4px; 
  border-style: solid;
  border-color: red; 
}
.social-links {
    padding: 15px;
  margin: 10px;
}

3 Answers

Jason Anders
MOD
Jason Anders
Treehouse Moderator 144,840 Points

Hi Steven,

Everything you have is correct. And while the indented line doesn't look nice, it won't affect the styling of the page or whether the challenge passes or not (Whitespace, for the most part, is irrelevant in CSS and HTML, and the Code Checker will not return a Bummer for it).

The problem here is that you deleted some code in the HTML file that was there when the challenge loaded. You deleted the code the was between the <head> tags. Considering these lines included the link to the style sheet, the code checker caught that error and returned the Bummer!

Just restart the challenge so all the lines are back and paste in what you've got.
And to keep things neat, you could remove that indent. :smirk:

Nice work! :dizzy:

Adam Pengh
Adam Pengh
28,838 Points

You do have the right code, it might be the .main-pg class or the extra indent on the padding rule. Treehouse is dumb like that sometimes.

Brandon Brown
Brandon Brown
4,239 Points

Remove the extra indent these practice courses are very specific about how to they want the code to be placed.

Steven Mercado
Steven Mercado
3,246 Points

Thank you very much :D