Using
Heading TagsHeading tags are predefined formatting tags. These are the
six heading tags.
<H1>,
<H2>, <H3>,
<H4>, <H5>, <H6>
Heading tags, as well as other HTML tags, describe what the
text is, not how it will be displayed. For example, you can
specify text as a heading or an address, but you cannot format
the text as being in 18-point Arial font. You tell the browser
what the text is, and the browser decides how that text will be
displayed.
Its important to remember that not all browsers display the Figure 1
same way, so you should keep your formatting simple.
There are a few guidelines to remember when using heading tags. Headings are designed to help make your Web page easy to read. You should use the heading tags in order. For instance, it is not recommended that you use a level 3 heading tag after a level 1 heading tag. Instead, you should use the level 2 heading tag after the level 1 heading tag.
To use heading tags in your Web page, do the following steps:
<H1>Welcome to my web
page.</H1>This page is currently under construction.
Your web page should look like this:

Notice the text is on two separate lines, even though the text is on the same line in your text editor. The heading tag includes a line break tag (<BR>) at the beginning and end, but the <BR> tag does not display. A line break is the same thing as pressing the Enter key in a word processor. When you use heading tags, a line break is inserted automatically before and after text.
If you wanted to make the document easier to read in your text editor, you could insert hard returns.
Notice that your Web page still displays the same even though there are blank lines in your text editor. Blank lines in your text editor do not affect the way the Web page is displayed in the browser because you didnt insert the HTML code for a blank line, <BR>. You can use as many blank lines in your text editor as necessary to make your document easier to read.
Practice using all the heading tags by doing the following steps:
Even though the heading tags made the text smaller, a line break is still inserted before and after the heading. As we continue, you will see that there are ways of emphasizing text without using the heading tags.
17. Change the title of your web page to Chapter 4 Exercise 1. View the final copy in your browser.
Style tags change the way your text looks. Style tags are similar to heading tags. The table describes some of the style tags you will use in this exercise.
|
Boldface |
<B> </B> |
|
Italic |
<I> </I> |
|
Emphasis |
<EM> </EM> |
|
Blink |
<BLINK> </BLINK> |
|
Big |
<BIG> </BIG> |
|
Small |
<SMALL> </SMALL> |
|
Address |
<ADDRESS> </ADDRESS> |
To see how style tags change your text, do the following steps:
Your insertion point should be under the <BODY> tag.
Your web page should look like this:

If your Web page does not look like the figure, check the source code in your text editor. Source code is the name for all the text in an HTML document. Your can view the source code in text editor or in your browser. However, you can only make changes to the source code in your text editor.
The source code for your Web page should look like this:

<HTML>
<HEAD>
<TITLE>Chapter
4 Exercise 2</TITLE>
</HEAD>
<BODY>
This is
<B>bold.</B><BR>
This is
<I>italic.</I><BR>
This page is
currently under construction.
</BODY>
</HTML>
If your Web page is not correct, compare your source code to the above code. Save the changes and refresh the file in your browser.
To use additional style tags in your Web page, do the following steps:
<EM>Emphasis</EM>
is similar to italics.<BR>
Some people think
<BLINK>blinking</BLINK>
text is annoying.<BR>
This is <BIG>big</BIG>
and this is
<SMALL>small.</SMALL><BR>
Your source code should look like this:

<HTML>
<HEAD>
<TITLE>Chapter
4 Exercise 2</TITLE>
</HEAD>
<BODY>
This is
<B>bold.</B><BR>
This is
<I>italic.</I><BR>
<EM>Emphasis</EM>
is similar to italics.<BR>
Some people
think <BLINK>blinking</BLINK>
text is
annoying.<BR>
This is
<BIG>big</BIG> and this is
<SMALL>small.</SMALL><BR>
This page is
currently under construction.
</BODY>
</HTML>
Your Web page should now look like this:

The <ADDRESS> tag is similar to italics. To see how the address tag works, do the following steps:
My address is:<BR>
<ADDRESS>__________________________</ADDRESS>
The same principles apply to underlining by using <U> and </U>. You can use several tags in combination. In order to do this, you will need to use nested tags.
To avoid confusing the browser, tags should be nested not overlapping. Study the following examples.
<I><U>cool</I></U> Overlapping tags .. bad!
<I><U>cool</U></I> Nested tags .. good!
Create a web page in HTML using the following guidelines.
Make the title be Chapter 4 Exercise 3
In the body, write your name and underline it.
Now duplicate Figure 1 from page 1 of this packet.
Then
1. Make 1 big word and a separate italic word between the <H1> tags.
In this exercise you will use what you have learned to create another Web page.
The table below shows the tags you learned in this chapter.
|
Headings (1-6) |
<H1> </H1> |
|
Boldface |
<B> </B> |
|
Italic |
<I> </I> |
|
Underline |
<U> </U> |
|
Emphasis |
<EM> </EM> |
|
Blink |
<BLINK> </BLINK> |
|
Big |
<BIG> </BIG> |
|
Small |
<SMALL> </SMALL> |
|
Address |
<ADDRESS> </ADDRESS> |
|
Line Break |
<BR> |
Using the tags in the above table, do the following: