The Complete HTML Teacher

Other Basic Tags





You have now learned how to set up your page, with the <HTML>, <Head>, <Title>, </Title>, </Head>, <Body>, </Body>, and </HTML> tags.

You have also learned how to determine colors for your background, text, links, visited links, and active links, using the <Body> tag, as well as how to insert a background image into your page.

You also know how to use fonts, font faces, font colors, and font sizes using the <Font></Font> tags.

Now, it is time to learn some other basic tags that make your text more interesting and fun to work with.

The other basic tags are:

Bold ~ <b></b> ~causes the text between these tags to be bold or strong.

Italics ~ <i></i> ~causes the text between these tags to be italicized.

Paragraph ~ <p> ~starts a new paragraph in your text. Does not require a closing tag.

Break ~ <br> ~causes a line break, like a return, without starting a new paragraph...it just starts a new line. Does not require a closing tag.

Non-Breaking Space ~ <nb> ~makes a space in your text, without causing a line break. It is not necessary to use this to make a regular space in your text. It is only necessary to use this between graphics really...to put space between them, if they are on the same line. Does not require a closing tag.

Underline ~ <u></u> ~causes the text between these two tags to be underlined.

Center ~ <center></center> ~causes the text between these two tags to be centered on the page. This tag is supposed to become obsolete within a few years, so it may be best to use the <div></div> tags instead.

Divide ~ <div></div> ~This tag also causes the text to be centered between these two tags. The same as the center tag, which is supposed to become obsolete someday.

If I typed the following line into my HTML document:

<center><b><i><u>I know how to use HTML tags!</u></i></b></center>

It would look like this:

I know how to use HTML tags!

These are all simple tags to learn, which you will soon have memorized!

There are a few more tags to learn as well.

If you want your text to blink, which is irritating to most people, so use caution, you would use the <blink></blink> tags.

<blink>This is an irritating blinking line</blink>

This is an irritating blinking line

You can also use lists. Now, there are ordered lists, and there are unordered lists. The unordered lists produce bullets next to each item on the list, while the ordered lists produce numbers next to the items in your list.

The tags for an ordered list are <ol></ol>. The tags for an unordered list are: <ul></ul>. Now, between these tags, you must use the list tag, which is <li>.

<ul><li>Item <li>Item <li>Item

The above line will produce:

  • Item
  • Item
  • Item

<ol><li>Item<li>Item<li>Item

The above line will produce:

  1. Item
  2. Item
  3. Item

Now, here are a few more basic tags...that you likely won't use very often:

Typewriter ~ <TT></TT> ~causes your text to appear as if it had been typed on a typewriter.

Horizontal Rule ~ <hr> ~This is actually a very useful tag for dividing up your page. It causes a horizontal line to be drawn across your page, and can be configured to be centered, to be colored, to be shaded or unshaded, and to be a certain percentage of the page, and a certain width.

For example, if you typed the following:

<hr align="CENTER" size="80%" color="Blue">

You would get the following line across your page:


Of course, you can also just simply use the <hr> tag all by itself:

<hr>

This will give you a horizontal line all the way across your page, like this:


There are also things you can do to the <p> tag. This is the paragraph tag. With this tag, you can align your text, either to the left, which is the default, to the right, or to the center.

For example, if I typed:

<p align="right">This text will align right.</p>

I would get:

This text will align right.

Now, you'll notice that if you just simply use the <p> tag all by itself, it does not require a closing tag...however, as soon as you add things to the <p> tag, you must follow the text that you are aligning with the closing tag, </p>.

Remember, you can either align left, right or center.

Well, that covers the basic HTML tags that you will find yourself using over and over....Ready for more?

Got It! Let's Move On!

Contents



Copyright ©1998 by K. Williams Resources. All Rights Reserved