[thelist] Decimal align

rudy r937 at interlog.com
Mon Aug 27 21:54:42 CDT 2001


> The new alignment attributes in HTML 4.0 say that you can use
> align="char" to align numbers on their decimal points.

hi bob

well, i wouldn't call html 4 exactly "new"  ;o)

> I guess I'm not understanding how it should be used.

here's the w3c's example

    <TABLE border="1">
    <COLGROUP>
    <COL><COL align="char" char=".">
    <THEAD>
    <TR><TH>Vegetable <TH>Cost per kilo
    <TBODY>
    <TR><TD>Lettuce        <TD>$1
    <TR><TD>Silver carrots <TD>$10.50
    <TR><TD>Golden turnips <TD>$100.30
    </TABLE>

        http://www.w3.org/TR/REC-html40/struct/tables.html#alignment

note that the char="." is supposed to be the default (assuming the browser
supports character alignment)

the nice part about the above example (if you can hold your nose to the
stink of upper case unclosed tags) is that the alignment is applied to the
column

otherwise it would end up being applied to each cell (yuck)


mark, have you really done it with css?  cool

i wonder if the class can be applied to the COL tag....


rudy






More information about the thelist mailing list