I’ll be writing a series of CSS tutorials for people who have some difficulties. This stuff is real basic, and I hope it’s understandable.
Part 1: What is CSS?
CSS stands for Cascading Style Sheets, and is used to change the display of XML documents, specificly HTML. It’s mostly used for styling web pages written in XHTML and HTML. The CSS standards are set and maintained by the World Wide Web Consortium (W3C).
Part 2: What can I do with CSS?
The folowing are some things you can do with CSS:
- Font properties such as typeface and emphasis
- Color of text, backgrounds, and other elements
- Text attributes such as spacing between words, letters, and lines of text
- Alignment of text, images, tables and other elements
- Margin, border, padding, and positioning for most elements
- Unique identification and generic classification of groups of attributes

Part 3: Great! Where do I start?
Well, the first thing you need to know about CSS is the syntax. First, there are a few difrent ways to style an element. You can use class, id, style, or the element its self. Lets get started on styling a class.
.style1{
font-size: 13px;
color: #000000;
}
Then, in your element, lets say a span element, you would set the class property to style1. Example:
<span class=’style1′>This text is black and 13px</span>
Another way of styling the element, by telling the element what to use is ID. This shoud ONLY be used with a unique tag, no 2 IDs on one page should be the same to keep your work XHTML. Here is what you’d do:
#div_id{
width: 200px;
height: 200px;
border: 1px solid #000000;
}
The usage of this would be in a div, or table. It can be used other places, but it’s most comon there. I would utilize this by doing this:
<div id=’div_id’>This is 200px square, with a 1px black border!</div>
Now, lets say we want every one of some element to have the same properties. For example, if we want ALL links to be black by default, without giving them each a class. You’d do this:
a{
color: #000000;
font-size: 13px;
}
This would make all links black, and 13 px. You’d use it just like you normally would, without the class or id tag. Just:
<a xhref="index.html" mce_href="index.html" >This is black and 13px!</a>
Now, inline CSS. I mentioned it above as style. Now, this uses CSS, but the syntax is slightly difrent. I’d use it like this, for example, in a span tag:
<span style=’font-size: 13px; color: #000000′>This is 13px and black!</span>
Although I wouldnt recomend using this for more than testing, it looks bad. You should copy that and add it to a ID in the CSS sheet.
Well, I guess that’s all for now. Next tutorial will be on the CSS properties.