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

linking css

when we link an external css file to html file like the example in the video < link rel="stylesheet" href="css/normalize.css" type="text/css" media="screen">, I noticed that for the type attribute, we use" text/css", not just "css"..why is that? I'm just curious. do we ever use just "css"???..I'm just curious...

4 Answers

Good question. The link tag can be used to link more than just CSS (though nowadays it is almost exclusively used for CSS), and when we specify the type, we are actually specifying the MIME type, and the MIME type name for text-based CSS just so happens to be text/CSS.

Here is the exact same question asked over at code academy about a year ago:

http://www.codecademy.com/forum_questions/507a8614b29a310200003391

Thank you!

I don't think that's the question she was asking John W. but thank you for your fabulous expertise. ;)

He did answer my question Carlos Perez, and thank you for not insulting me again! :)

I insulted you? Oh dear sorry if you felt that.

well i guess its because CSS is text based code like how we also use text/html

Yeah..I think that's the reason :)