CSS is your friend

Believe me when I say, CSS (cascading style sheets) is your friend. Many of the tags used in HTML 4.0 have deprecated and are no longer suggested for use. Instead, styling via CSS is the preferred method of controlling these things.

For example, the font tag is no longer in use, now you use CSS font-family, font-size, etc. Some people also use font-color, however color is the appropriate tag to use, as font-color does not work. I have seen this used in style sheets before, and it “worked” because the text color was browser default black anyways.

CSS is easy to pick up on. You just have to get started. It’s not like you’re learning to create digital signage or anything. ;) Here are a few tips to help you out. :)

When you start styling an element, you want to do it as follows (I am using the body element as an example):

body {
        background-color: #000;
        color: #fff;
        margin: 0px;
        }

In this example, body is the element you are styling. To add a background color you can either use background: or background-color: as your tag. It works either way. However, I usually use color as you can also use an image for your background by putting background-image: url(‘urltoyourimage’); as well.

Color: is going to be your font/text color. Margin: is your page margins. There are many elements you can style. You can also put your font-family and font-size in the body styles if you like.

You can style your links using a:, a: hover, a: active, and a: visited.

These are just basic CSS examples to get you started. You can learn more by going to W3 Schools. :)

(Edited to correct something, that was typed in here. A friend was helping me out by typing up something I had written out for her and apparently either couldn’t read what I had written, or had decided to make some changes to it.)

Be Sociable, Share!

No related posts.

Related posts brought to you by Yet Another Related Posts Plugin.


7 thoughts on “CSS is your friend

  1. Pingback: Posts about CSS as of February 9, 2009 | XHTML and CSS

  2. Perhaps it'd be wise to check out CSS shorthand tutorials or something cause the CSS tags you're trying to teach will take up unnecessary space. I don't see the need to try teaching visitors about CSS when you don't really explain anything at all. Just an opinion since there are quite some people who are experts on the subject whom already have written quite a few tutorials on the topic.

  3. First, I am not teaching anything, if I were, there would not be a reference to W3 Schools for people to learn more. I am merely trying to give some advice to people who might be trying to start desiging their own pages/themes. Besides, it is my blog and I have the right to post what I want on it. If I wish to teach about CSS, I will do so.

  4. You have indeed the right to post about anything you want on your post. That doesn't mean however that the advice you're giving is correct.

  5. You have indeed the right to post about anything you want on your post. That doesn't mean however that the advice you're giving is correct.

  6. You have indeed the right to post about anything you want on your post. That doesn't mean however that the advice you're giving is correct.

  7. Pingback: Installing Wordpress Locally So You Can Modify or Create Wordpress Themes | New Blog Help

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>