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 trialCharles Steinmetz
14,420 PointsI am having trouble getting an external style sheet to link. I have followed the instructions but cannot get css to show
I saved the CSS course to the desktop and created the style.css file into the css folder. Following the instructions exactly but cannot get the rules to apply?
Index.html is:
<!DOCTYPE html> <html> <head> <title>Adding CSS</title> <link rel"stylesheet" href="css/style.css"> </head> <body>
style.css is:
h2 { color: steelblue; padding-bottom: 10px; border-bottom: 2px dotted; }
ul { color: white; background-color: steelblue;
}
2 Answers
banu babanu
8,152 PointsIf your css file is into the css folder you must have this code:
<head>
<link rel="stylesheet" type="text/css" href="css/style.css">
</head>
Ali RahimDabagh
2,296 PointsDear friend just remember some steps so as to not encountering such this problems:
- check out the link syntax and the path
- check out your css rules syntax very carefully
- in order to debug your problem comment your css`s rules and check them one by one by removing comment from each rule good luck
Charles Steinmetz
14,420 PointsCharles Steinmetz
14,420 PointsFigured out I left the = sign out between the rel and stylesheet. Thanks!