Welcome to Our Free Tutorial!

Internal - CSS

Cascading Style Sheet (CSS) has three flavors: internal, external, and inline. The Internal and External are the only use designer. In this lesson, we cover the easier type Internal.

When we using internal CSS, you must add a new tag, <style> tag inside the <head> tag.

CSS Code:

<html>
<head>
<style type="text/css">
</style>
</head>
<body>
<p> page's content here!</p>
</body>
</html>

This code does not do anything visually. This code just tell to the browser that we defining some CSS to be used on this page.

Creating Internal CSS Code:

CSS Code:

<html>
<head>
<style type="text/css">
p {color: blue; }
body {background-color: yellow; }
</style>
</head>
<body>
<p>Blue text on a yellow background!</p>
</body>
</html>

Display:

Blue text on a yellow background!

You may noticed that in our CSS code we are altering the <body> and <p> HTML tags.

Explanation

We know that <p> and <body> both are HTML tags. We clarify that step by step process what is going in the first line of CSS code.
1. We chose HTML element to manipulate- P{: ;}
2. Then we chose the CSS attribute color. P{ color: ;}
3. Last we choose the font color is blue.- p{color: blue;}
    Now all text into a paragraph tag will show as blue! Now let’s explanation of the CSS Code altegreen; <body> background:
1. We chose HTML element to manipulate Body- body{: ;}
2. Then we chose the CSS attribute. Body { background-color: ;}
3. Last we choose the background color is yellow.- body {background-color: yellow;}

Advantages of CSS

1. Place CSS Code between opening  <style> tag and Closing </style> tag.
2. Write correct format (syntax) of CSS Code.
3. CSS save your hours of time.