![]() |
HTML Tutorial 2Web Page Structure |
|
|
The HTML language is written in the form of 'tags' which dictate some characteristic of the web page or its content. Tags consist of some text within angular brackets eg <html>. Some HTML elements have opening and closing tags. For example the start of a web page is defined by <html>, and the end of the page defined by </html>. These are called container tags. Other elements are defined by a single tag, for example an image would be inserted by <img src="myimage.gif">. Comments start with <!-- and end with -->. In these tutorials they will be colored green to distinguish them from the other tags.
A web page is divided into two main sections, a head section and a body section <html> The head section contains information about the web page, but not content which appears on the page. The body section is where the content appears.
The <title> tag is the most important tag in the head section. It provides a summary of the content of the page and is important as it is indexed by some search engines. The content of the title tag also appears in the results of queries in some search engines. On a web page, the title can be seen inthetop left corner of the browser, above the File and Edit menu titles. The title tag for this page is: <title>Knowledge River - HTML Turorial 2</title>
The <body> tag identifies the start and finish of the page content. By adding other optional parameters or information into the body tag characteristics of the page as a whole can be specified. Note that a web page only ever has one body tag. If parameters are included, they are added into the same tag. Optional parameters: Background color Background Image Text color Fixed background Link color Active link color Visited link
color Left margin width Top margin width The complete body tag made up of all the above elements would therefore be: <body bgcolor="#ff0000"
background="myimage.jpg" text="navy" bgproperties="fixed"
link="green" alink="yellow" vlink="red"
leftmargin="0" topmargin="0"> |
| © & Design by systemalchemy.com |