What is the Proper Way to Use an HTML Code Tag?

Article Details
  • Written By: Mary Elizabeth
  • Edited By: Bronwyn Harris
  • Last Modified Date: 27 September 2019
  • Copyright Protected:
    Conjecture Corporation
  • Print this Article
Free Widgets for your Site/Blog
U.S. companies first sold energy drinks in the early 1900s; they contained radium, which causes radiation sickness.  more...

October 19 ,  1987 :  The Dow Jones experienced its second-largest percentage drop in history.  more...

HTML is the standard abbreviation for Hyper Text Markup Language, a means of structuring documents that are used to create web pages. The structure is created by enclosing each bit of page text with an opening and closing HTML code tag that together define the element that is to appear at that point in the document. HTML code tags that stand alone are also used to perform other functions. For the material to appear as desired, each HTML code tag must be properly structured and placed in proper relationship to other code tags and to content.

There are several key steps in forming an HTML code tag. First, a tag must begin with the symbol , which is sometimes called a “greater-than sign,” and sometimes called a “right angle bracket.” This is the case whether the HTML code tag is an opening tag, a closing tag, or a stand-alone tag.


In some cases, an HTML code tag stands alone with its content. This is the case, for example, with the tag <br>, which creates a line break. There is no need for a paired closing tag for this function. When code tags work in pairs as an opening and a closing tag, there is another requirement. In this case, the left bracket of the closing tag must be followed by the forward slash sign /. For example, to make material appear as boldface, the content of the HTML code tag is the letter b, so the HTML rendering would look like this:

<b>the words I want to be bold</b>

The material within the brackets of an HTML code tag is always specified, sometimes by exact material, like b for bold, and sometimes by the class of item that must be included. For example, to create a hyperlink, a URL for a web page—any web page you like—must be specified inside of the opening HTML code tag, while the word(s) you want the reader to see are placed between the opening and closing tags like this:

<a href=””>words the reader sees</a>

To make this work, you replace the URL with the URL you want the link to go to and replace “words the reader sees” with the words you want in place. Notice that besides the letter a, that appears in the closing tag, the opening tag has a space, the designation href, an equal sign, and opening and closing quotation marks around the URL. All of these elements are necessary for the HTML code tagging to work properly.


You might also Like


Discuss this Article

Post 1

Each page must define its document type, always close HTML tags except self-closing tags, proper nesting required, be careful about attributes and at last validate your page.

Post your comments

Post Anonymously


forgot password?