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 trialYvette Uhl
3,607 PointsHow should I write a css rule for a border to have the color red?
Not able to get my border to show up. I have tried putting the width, style and color for the border in different orders to get my border to show as well as specifying border-width, border-style and border-color in the styles.css tab. Curious to find out what I'm doing wrong.
<!doctype html>
<html>
<head>
<link href="styles.css" rel="stylesheet">
</head>
<body>
<p class="main-pg"> My amazing website</p>
</body>
</html>
<style>
.main-pg{
border: 4px solid red;
}
</style>
1 Answer
james south
Front End Web Development Techdegree Graduate 33,271 Pointsif you are linking to a separate css file, you don't need the style tags.
Yvette Uhl
3,607 PointsYvette Uhl
3,607 Pointsthanks!