W3C home > Mailing lists > Public > www-html@w3.org > October 2002

Re: xhtml strict - how to have caption below table and caption text with smaller font size

From: Ralf Hauser <hauser@acm.org>
Date: Tue, 22 Oct 2002 07:30:11 +0200
To: www-html@w3.org
Message-ID: <ap2nl9$j02$1@main.gmane.org>

Christoph Päper wrote:
> Ralf Hauser <hauser@acm.org>:
> 
>><caption align="bottom" style="font-weight:bold"><small>Building blocks
>>to improve mail privacy</small></caption>
>>
>>1) How to do the same in valid xhtml?

> [3), 4). In style.css:]
> 
> caption {font-weight: bold; font-size: smaller}
> table   {caption-side: bottom}
Thanks - to bad MSIE 6 doesn't know the "caption-side" attribute.

Other good advice I got from andrew_kirkpatrick@wgbh.org:
and you'd have a css declaration like:
...
font-weight: bold;
...
If you had multiple tables with captions, you could use id's or class 
attributes to distinguish between them:

<caption id="foo">jfkdsjkfld</caption>

and in the style sheet:

#foo {
font-weight: bold;
font-size: .85em;
}

or...

<caption class="foo">jfkdsjkfld</caption>
and...

caption.foo {
font-weight: bold;
font-size: .85em;
}

Hope this helps.  Feel free to look at one of our strict sites 
(http://ncam.wgbh.org/salt/guidelines).
Received on Tuesday, 22 October 2002 01:29:17 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 27 March 2012 18:15:53 GMT