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

CSS

I am trying to build a website using html and css. I can't seem to get the html and css documents to link together.

<!DOCUTYPE> <html lang-"en"> <html> <head> <title>Learning a New Skill</title> <link href="backgound.css" rel="stylesheet" type="text/css"/>

<body>

<h1>New Skills</h1>

<h2>Written with some struggle moments by Chantrice</h2>

<h3>My Laptop, GA</h3>

<p>Learning a new skill is difficult. Coding is a very challenging field of study. </p>

</body>

</head>

</html>

4 Answers

Also you've got a typo in <!Doctype html>

Thank You I will fix it now.

check where you saved your css file

They are both saved in the same folder.

alright, it's in the root folder

Try correcting your code to this

<!DOCTYPE html> <head> <title>Learning a New Skill</title> <link rel="stylesheet" type="text/css" href="background.css"> </head>

<body>

<h1>New Skills</h1>

<h2>Written with some struggle moments by Chantrice</h2>

<h3>My Laptop, GA</h3>

<p>Learning a new skill is difficult. Coding is a very challenging field of study. </p>

</body>

</html>

I just retyped the entire page and it still will only show the html. I am going to go back over how to build the css file. I think the error might be in there. Thank you for all your help.

Try using <link rel="stylesheet" type="text/css" href="background.css">. is your css file in a folder or in root folder ?

Thank you for the response. I have use that line multiple times. How do I know if my css is saved inside my root folder?