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 How to Make a Website CSS: Cascading Style Sheets Use ID Selectors

Ray Cabatingan
Ray Cabatingan
3,549 Points

CSS styling does not apply to my webpage despite correct syntax. (i guess so)

As I was going through with this course initially I can reflect the changes using <style></style> tag at the head element. later on when linking to main.css styling no longer applies. I have checked <link></link> syntax as well as the proper rule syntax on main.css still syling does not apple

Carlos Martinez
Carlos Martinez
10,660 Points

Would you be able to show us your code.

Ray Cabatingan
Ray Cabatingan
3,549 Points

Carlos, Thanks for the reply.... sorry for my missing code forogot to snap it here. the problem was already resolved. I mistakenly used <!-- --> to write my comments(notes) on the main.css file instead of /* */.

1 Answer

Hi Ray,

As Carlos has suggested it would be great to see your code in detail. However from your question you reference the main.css file.

Is your main.css in a css directory?

If so be sure to use the href="css/main.css" to correctly link to your file.

Craig

Ray Cabatingan
Ray Cabatingan
3,549 Points

Craig, Thanks for the reply.... sorry for my missing code forogot to snap it here. the problem was already resolved. I mistakenly used <!-- --> to write my comments(notes) on the main.css file instead of /* */.