Home Page | Table of Contents | View MTX File | Previous Page | Next Page

Tables


Introduction | MTX Table Format | Examples

Introduction

Tables are one of the most advanced HTML formatting capabilities. Tables consist of several elements:

Web browsers dynamically display tables based on the current window size, font selection, and other parameters. While it is possible to create exquisitely customized HTML tables, the communication value of a table tends to decrease in proportion to its complexity. MTX provides a simplified and flexible format for defining tables.

MTX Table Format

Use a leading vertical bar (|) to tag lines that will become part of a table. Each new line becomes a row in the table. Use additional vertical bars (|) to delimit columns within each row of a table. Here is an example:
|A Simple Table
|      |*col 1|*col 2|*col 3
|*row 1|one   |two   |three
|*row 2|four  |five  |six
|*row 3|seven |eight |nine

The first line of the table contains the caption and other formatting information. Leave this line empty or use the "none" switch to suppress the caption. Place a leading star (*) character in a cell to create a row or column heading. Empty cells will be blank unless they contain a single star (*) character. Place a leading caret (^) to force the text in a cell to be top aligned (the default is vertically centered). Use spaces to pad lines for better source file readability. Use the line break tag {BR} to force a line break within a cell.

It is possible to have a cell that spans more than one column. Use the back slash (\) character followed by the number of columns to span:

|col 1 |span\2 |col 4

By default, tables will expand to fill 95% of the width of the current window. This can be overridden by using the "nowide" switch after the caption. The table border can be suppressd by using the "noborder" switch. Blank cells can be suppressed for the entire table by using the "noblanks" switch. These switches can be combined by adding additional vertical bars (|). Here are some examples:

|A Skinny Table|nowide
|An Invisible Table|noborder
|A Skinny, Invisible Table|nowide|noborder
|A Table with No Blanks|noblanks

Tables are not universally available. Current versions of Netscape and NCSA Mosaic support tables. Web browsers from America Online and certain other online services do not.

Examples

A Simple Table
col 1col 2col 3
row 1onetwothree
row 2fourfivesix
row 3seveneightnine

A More Complex Table
col 1col 2col 3
row 1one
two
three
Flower Picture
row 2This is a long line of text that must all fit in the cell.fivesix
row 3hypertext linknine
row 4ten and eleventwelve

A Skinny Table
col 1col 2col 3
row 1onetwothree
row 2fourfivesix
row 3seveneightnine

An Invisible Table
col 1col 2col 3
row 1onetwothree
row 2fourfivesix
row 3seveneightnine

A Skinny, Invisible Table
col 1col 2col 3
row 1onetwothree
row 2fourfivesix
row 3seveneightnine

A Table with No Blanks
 col 1col 2col 3
row 1   
row 2 five 
row 3   

A Calendar Table
September 1996
MondayTuesdayWednesdayThursdayFriday
2
Labor Day
3
Small Group
Video Interview
Class
4
Small Group
Video Interview
5
Small Group
Video Interview
6
Small Group
Video Interview
9
Small Group
Clinic
Class
10
Small Group
Clinic
11
Small Group
Clinic
1213
1617
Unit 1 Exam
18
Unit 1 Exam
19
Small Group
Clinic
20
Small Group
Clinic
23
Small Group
Class
24
Small Group
25
Small Group
Class
26
Small Group
Midterm Review
27
Small Group


 Updated: July 13, 1996 at 8:25 PM
 Version: MTX 1.4 User's Manual / Copyright 1996 by the University of Florida
Location: http://www.med.ufl.edu/medinfo/mtx/docs14/tables.html
  Author: Richard Rathe / rrathe@dean.med.ufl.edu

Home Page | Table of Contents | View MTX File | Previous Page | Next Page