Cascading Style Sheets come in three flavors: internal, external, and inline. We will cover internal and external, as they are the only flavors a designer should utilize. In this lesson, we cover the basics of the easier type, internal. When using internal CSS, you must add a new tag, <style>, inside the <head> tag. The HTML code below contains an example of <style>'s usage
Place your CSS Code between <style> and </style>:
<html> <head> <style type="text/css"> </style> </head> <body> <p>Your page's content!</p> </body> </html>
This doesn't actually do anything visually. The code style tag just tells the browser that we
Create CSS Code:
<html> <head> <style type="text/css"> p {color: white; } body {background-color: black; } </style> </head> <body> <p>White text on a black background!</p> </body> </html>