The CSS (cascade style sheet) language is pretty easy to learn. It's very vital for all web designers any anything else involving said web design. This tutorial will cover the basics of CSS to intermediate.
Let's start!
1. A rule in CSS is basically what you call the snippet of CSS, example:
- Code:
-
.example {}
2. You must always start and end with "{" which starts the rule off, and end the rule with "}"
3. defining between div class and div id and targeting more than one div, these are always what confuse certain people, example:
- Code:
-
.example, .example2 {}
that means it's targeting two div tags which would be,
- Code:
-
<div id="example"></div> and <div id="example2"></div>
and the classes would be, example:
- Code:
-
#example {} #example2 {}
which in HTML are
- Code:
-
<div class="example"></div> and <div class="example"></div>
but all in one CSS rule. It's pretty handy for economising and keeping things tidy.
Not yet finished