Basic HTML - a brief explanation

To start out with there are 2 main sections of an HTML document (aka - a web page). The HEAD and the BODY. Using these two section you have a standard skeleton for your HTML document. Here is an example below;

  1. <html>
  2.        <head>
  3.            <title> </title>
  4.           HEAD Content Here
  5.        </head>
  6.        <body>
  7.            BODY Content Here
  8.        </body>
  9.     </html>

Now, lets take a close look at each part of the HTML document.

For starters, the whole document should be wrapped inside of the <HTML> </HTML> tags. You will notice that the is one at the beginning as well as the the end, the only difference between them is the / in the end one. This / is used to close a tag. All HTML tags should be closed, either by using a close tag such as the </html> or for some tags that do not have a close to them you close it with in it’s self. You will learn over time which way to close each tag.

Examples;

Tags with closing tags;

  1. <html> </html>
  2. <p> </p>
  3. <table> </table>

Tags that do not have a close tag (you close these with in it’s self);

  1. <br />
  2. <meta />
  3. <hr />

Ok, now lets look at the HEAD section.

Anything you put in the HEAD section will not show up in the browser. This is where you put your <style> tags for using CSS, and your <script> tags when working with JavaScript, and all your <meta> tags. I will try to get into what each of these are in other posts.

This is also where you set the title of your web page using the <title> tag. This is one of those tags that has a close tag with it (<title>Your Title</title>). What you enter in the title tags is what shows up in the browsers title bar. Like if you look up at the tile bar right now, you will see “MichaelNoga.com << Blog Archive << Basic HTML - a brief explanation. Normally you would want to keep this title short and relevant to the info on that web page. It will help with search engines as well.

And now, the BODY section.

The BODY is where all your content goes, everything you want visitors to see goes right here. What you’re reading right now is content between the BODY tags. I will get into more detail about how to format your content and what other HTML tags you can use to make it look good.

As always, let me know if you have any questions for would like to request a topic for me to cover.

This entry was posted on Monday, November 13th, 2006 at 11:58 pm and is filed under Getting Started, Web Design. You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.

 

Leave a Reply