<TR>NN all   IE all   HTML all
<TR>...</TR>End Tag: Optional
 

A TR element is a container for one row of cells. Each cell within a row may be a TH or TD element. Every row requires at least a start tag to instruct the browser to begin rendering succeeding cell elements on the next line of the table. Other special-purpose row groupings available are the TFOOT and THEAD, as well as the more generic TBODY grouping element.

 
Example
<TABLE COLS=3>
<THEAD>
<TR>
<TH>Time<TH>Event<TH>Location
</TR>
</THEAD>
<TBODY>
<TR>
<TD>7:30am-5:00pm<TD>Registration Open<TD>Main Lobby
</TR>
<TR>
<TD>9:00am-12:00pm<TD>Keynote Speakers<TD>Cypress Room
</TR>
</TBODY>
</TABLE>
 
Object Model Reference
IE [window.]document.all.elementID
ALIGNNN n/a   IE 4   HTML 4
ALIGN="alignConstant"Optional
 

Establishes the horizontal alignment characteristics of content within the row. The HTML 4.0 specification defines settings for the ALIGN attribute that are not yet reflected in the CSS specification. Therefore, this ALIGN attribute is not fully deprecated as it is for many other elements. As a rule, alignment should be specified by style sheet wherever possible.

 
Example
<TR ALIGN="center">
 
Value
Navigator and Internet Explorer share the same set of attribute values, whereas HTML 4.0 specifies two additional values:
Value NN 4 IE 4 HTML 4.0
center
* * *
char
- - *
justify
- - *
left
* * *
right
* * *
The values center, left, and right are self-explanatory. The value justify is intended to space content so that text is justified down both left and right edges. For the value char, the CHAR attribute must also be set to specify the character on which alignment revolves. In the HTML 4.0 specification example, content that does not contain the character appears to be right-aligned to the location of the character in other rows of the same column. It is important to bear in mind that the ALIGN attribute applies to every cell within the TR element, including any TH element you specify for the table. If you want a different alignment for the row header, override the setting with a separate ALIGN attribute or text-align style sheet attribute for the TR or individual TH elements.
 
Default center
 
Object Model Reference
IE [window.]document.all.elementID.align
BGCOLORNN 3   IE 4   HTML 4
BGCOLOR="colorTripletOrName"Optional
 

Establishes a fill color (behind the text and other content) for the cells contained by the TR element.

 
Example
<TR BGCOLOR="lavender">
 
Value
A hexadecimal triplet or plain-language color name. A setting of empty is interpreted as "#000000" (black). See Appendix A for acceptable plain-language color names.
 
Default Varies with browser, browser version, and operating system.
 
Object Model Reference
IE [window.]document.all.elementID.bgColor
BORDERCOLORNN n/a   IE 3   HTML n/a
BORDERCOLOR="colorTripletOrName"Optional
 

The color used to render some of the pixels used to create the illusion of borders around cells and the entire table. Internet Explorer applies the color to all four lines that make up the interior border of a cell. Therefore, colors of adjacent cells do not collide.

 
Example
<TR BORDERCOLOR="green">
 
Value
A hexadecimal triplet or plain-language color name. A setting of empty is interpreted as "#000000" (black). See Appendix A for acceptable plain-language color names.
 
Default Varies with browser and operating system.
 
Object Model Reference
IE [window.]document.all.elementID.borderColor
BORDERCOLORDARK, BORDERCOLORLIGHTNN n/a   IE 3   HTML n/a
BORDERCOLORDARK="colorTripletOrName"
BORDERCOLORLIGHT="colorTripletOrName"
Optional
 

The 3-D effect of table borders in Internet Explorer is created by careful positioning of light and dark lines around the page's background or default color (see Figure 8-4 in the TABLE element discussion). You can independently control the colors used for the dark and light lines by assigning values to the BORDERCOLORDARK (left and top edges of the cell) and BORDERCOLORLIGHT (right and bottom edges) attributes.

Typically, you should assign complementary colors to the pair of attributes. There is also no rule that says you must assign a dark color to BORDERCOLORDARK. The attributes merely control a well-defined set of lines so you can predict which lines of the border change with each attribute.

 
Example
<TR BORDERCOLORDARK="darkred" BORDERCOLORLIGHT="salmon">
 
Value
A hexadecimal triplet or plain-language color name. A setting of empty is interpreted as "#000000" (black). See Appendix A for acceptable plain-language color names.
 
Default Varies with operating system.
 
Object Model Reference
IE [window.]document.all.elementID.borderColorDark
[window.]document.all.elementID.borderColorLight
CHARNN n/a   IE n/a   HTML 4
CHAR="character"Optional
 

The text character used as an alignment point for text within a cell. This attribute is of value only for the ALIGN attribute set to "char".

 
Example
<TR ALIGN="char" CHAR=".">
 
Value
Any single text character.
 
Default None.
CHAROFFNN n/a   IE n/a   HTML 4
CHAROFF="length"Optional
 

Sets a specific offset point at which the character specified by the CHAR attribute is to appear within a cell. This attribute is provided in case the browser default positioning does not meet with the design goals of the table.

 
Example
<TR ALIGN="char" CHAR="." CHAROFF="80%">
 
Value
Any length value in pixels or percentage of cell space.
 
Default None.
VALIGNNN n/a   IE 4   HTML 4
VALIGN="alignmentConstant"Optional
 

Determines the vertical alignment of content within cells of the column(s) covered by the TR element. You can override the vertical alignment for a particular cell anywhere in the row.

 
Example
<TR VALIGN="bottom">
 
Value
Four constant values are recognized by both IE 4 and HTML 4.0: top | middle | bottom | baseline. With top and bottom, the content is rendered flush (or very close to it) to the top and bottom of the table cell. Set to middle (the default), the content floats perfectly centered vertically in the cell. When one cell's contents might wrap to multiple lines at common window widths (assuming a variable table width), it is advisable to set the VALIGN attribute to baseline. This assures that the character baseline of the first (or only) line of a cell's text aligns with the other cells in the row--usually the most aesthetically pleasing arrangement.
 
Default middle
 
Object Model Reference
IE [window.]document.all.elementID.vAlign
Hosted by uCoz