H T M L

PAGE (3 of 7)

HTML Tags

WYSIWYG vs. Structure

Word processing is done either with a WYSIWYG, (What You See Is What You Get), word processor or a markup language. Web documents fit into the latter category.

A markup language is a meta-language. When composing a document in a markup language the author must include instructions/commands in the meta-language that describes the structure/organization/layout of the text. The markup language commands have no semantic relationship to the text of the topic.

Formatting Your Web Page

Tags are the essense of the HyperText Mark-up Language. Web Browsers read/scan an HTML file and interpret the tags as instructions on how the page should be structured/formatted or what functions to execute.

These tags are selected words enclosed within angle brackets < > which surround the text or object (image, link, etc.) that is being formatted. Most tags comes in a pair, there is one to open it and one to close it. The closing tag has a forward slash / following the "less-than" bracket.

Example:

<CENTER>Center this text.</CENTER>

Web browsers ignore white space - that is - tabs, carriage returns and extra spaces between words. Special tags can be used to preserve white space in a document, such as the <PRE> tag.

As an example of HTML code, consider the following minimal HTM doucment:

			
     <html>
     <head>
     </head>
     <body>
     This is the text in my HTML document.
     </body>
     </html>

To see the above HTML document formatted in a separate Web browser, (HTML 
formatter program), window click here.

HTML supports a number of formatting options. That makes it relatively easy to learn, but limits the looks of the documents you can create. Each Web browser client is responsible for handling the HTML markup language tags correctly. Although there are standards, Web brower developers are always pushing the boundaries of the technology past the standards. Thus implementations of tags, especially newer tags will differ among Web browsers, and what looks good when viewed with one Web browser may not look as nice or the same or even display on another.


 

 

A Bit About Style

Be aware that when designing your pages, not only should you pay attention to content, but also to the presentation. Using as many cool HTML features as you can on one page may be too distracting. If the page is difficult to read, it's unlikely that the reader will stick around long enough to get the content.

The Yale C/AIM WWW Style Manual is a very good and accepted reference on WWW publishing style.

 


© CS Dept Va Tech, 1997.

All rights reserved.