Collected by Elizabeth Janson Home Page |
|
One small point - close your tags. Netscape gets upset, and style sheet definitions do not know when to stop, unless the tag that started the action, is also ended. So get a habit - shut the gate!
Remember to close the <P> tag before the TABLE. If you fail to close the P element before the following table, IE4 will treat the table as part of the P element, which is incorrect. (For example, if you have <A NAME="here"></A> at the end of your TABLE, to mark a new section, the LINK opens in the TABLE, instead of after it.)
Netscape treats tables almost like they're completely separate from the main document. Therefore, you may be surprised to find that styles you applied to the BODY section aren't inherited by your tables.
Table ElementsWe are familiar with the standard TABLE tags, TR, TD, COLSPAN and ROWSPAN to manage the cells in the table grid. TH is used instead of TD to define a Heading
The TABLE tag includes width (may be a percentage of page width, eg 70%), cellspacing="20" (distance between cells) and cellpadding="20" (distance of edge of the cell from the contents of the cell).
Background colour 'BGCOLOR' can be used in the TABLE, TR and TD tags. A <TD> bgcolor will override a <TR> bgcolor and a <TR> bgcolor will override a <TABLE> bgcolor. Fixing the font used in each cell - Try this in your <table> tag: style="font-family:fixedsys" (or your choice)
'cellspacing=0' removes the inner border-line.
Contents of the cell are arranged horizontally using ALIGN=center, left or right.
BORDERCOLORLIGHT and BORDERCOLORDARK HTML 4 includes mechanisms to control border styles
Table attributes are id, class (document-wide identifiers), Start by trying a style-sheet table? Sorry, Netscape may not like it.
ROW groupingCAPTION, THREAD, TBODY and TFOOT are described hereCOLUMN groupingCOLGROUP, COL and their ways are described hereBORDERCell margins (the spaces between the cells) are handled by 'border-collapse', which solves some problems (and increases the Learning Curve), and is described hereThe Separated Borders Model is described here FRAME and RULE are described here Real-life examplesA practical example of tables with coloured rows is described hereIt looks like a TABLE but has no 'table tags', it used CSS to position each row and column. See it here Dynamic ActivityNew in HTML 4.0 is the ability for a TABLE itself to be active in terms of the mouse and keyboard, shown hereNetscape and IE5 handle mouse events differently. Coping with this is described here Next is row grouping here
|
Email CSS begins here |
|
This page is part of Elizabeth Janson's web site
http://www.oocities.org/elizatk/index.html
Tetbury residents in the Eighteenth Century my Australian Family History and Barrie, our Family Poet. |