Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

HTML Introduction to HTML and CSS (2016) Getting Familiar with HTML and CSS Test: Changing the Look of a Web Page

please help

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

    h1{color: purple;}

  </body>
</html>
styles.css
h1 {
  color: blue;
}

1 Answer

The first challenge question is to change the paragraph tag to an h1 tag. You've got h1 on there, but it needs to be in proper HTML tag markup, and you seem to have lost your closing tag. If you refresh the page, you should get the original paragraph tag back (or just copy/paste the tag I've included below).

<p>Welcome to My Web Page!</p>

Then, all you need to do is change both of the 'p' characters to h1 (both the opening and closing tags).

The second challenge question asks you to change the color to purple. There should be a hint on your screen telling you that you can go to the "styles.css" tab. There, you can just change "blue" to "purple" to complete the second part of the challenge. It looks like you've put the CSS style for the h1 element in the html file where the <h1> tag should go instead of in the style sheet.

If you want to, you could use an inline style like the one you have above, but you need to write it in the correct HTML syntax as an attribute of the h1 element. Also, it is typically a best practice to keep all styles that you may reuse in a style sheet. However, if you still want to do an inline style, that would look like this:

<h1 style="color: purple;">Text goes here</h1>