Using CSS

Applying CSS Styles To HTML Elements

There are 3 ways to apply css styles to your web pages.

Inline:
Applying the css directly to an html element/tag within the html using the "style" attribute.
Internally
Defining the css style properties in the head section of each web page using the html "style" element.
Externally
Defining the css style properties in an external css file that is linked to by the html pages using the "link" element within the head section of the html file

It is recommended to use inline css styles sparingly as it counteracts the functionality of using css. It is far better to define your styles in the head of the web page, and ideal to use external css style sheets.

Lets take a look at how to use css in the above mentioned ways.