|
Tables
Tables are made in the followng way:
First, to specify that you are creating a table, use the tag <TABLE>
Next, use the tags <TR> & </TR> To specify the beginning
and end of a row. Between these two tags you place all that you want to
go on that particular row.
You now use the tags <TD> & </TD> To specify the beginning
and the end of what is in a particular column inside the particular row.
To take an example look at the following:
<TABLE>
<TR>
<TD> This is a message in the first row of the first column of
the table </TD>
</TR>
</TABLE>
To make the first row of every column appear in bold as a header
the tags <TH> & </TH> are used instead of <TD>
& </TD>.
A few other interesting features are the commands that appear inside the
actual <TABLE>
tag. These are the commands CELLPADDING & BORDER,. These are used to specify
the amount of "padding" between each cell in the table and to make the
table have a border. These are specified with an equals sign (=) and a
number. e.g.
<TABLE CELLPADDING=15 BORDER=10>
Now we incorporate this into our example from the last pages:
<HTML>
<HEAD><TITLE>Iceman's Web Page</TITLE></HEAD>
<BODY TEXT="#000000" ALINK="#FFFF00" VLINK="#8080FF" LINK="#0000FF"
BACKGROUND="greyweave.gif">
<H1>This is a heading of size 1</H1><BR>
<FONT COLOR="#FFFF00"><H1>This is a heading of size 1
in a different colour (yellow) </H1></FONT><P ALIGN="RIGHT"
ID="ice_verdanaHead">
<FONT SIZE=+2 FACE="Verdana">This is text of font size +2 and
in the Verdana Font, Aligned on the Right</FONT></P>
<!-- This is a comment, it won't appear in the browser, but is useful
when looking at source code. -->
<A HREF="mypage.htm">
This is a hyperlink to mypage.htm (Don't Click This!!)</A><BR>
<A NAME="middle">This is an anchor: you can't see anything
though!
<CENTER>
<A HREF="nextpage.htm">
<IMG SRC="mail.jpg" BORDER="2" HSPACE="2" VSPACE="2">
</A>
</CENTER>
Don't Click This Either!!
<TABLE CELLPADDING=15 BORDER=10>
<TR>
<TD>This is a message in the first row of the first column of
the table</TD>
<TH>This is a header in the first cell of the second column</TH>
</TR>
<TR>
<TD> This is a message in the second row of the first column of
the table</TD>
<TD> This is a message in the second row of the second column
of the table</TD>
</TABLE>
</CENTER>
</BODY>
<HTML>
Click Here for the Resulting Page.
O.K Try it out!
|
|