Skip to: content, navigation

by Tommy Olsson and Paul O’Brien

caption-side (CSS property)

Browser support full matrix
IE7 FF1+ Saf1.3+ Op9.2+
None Full Full Full
Spec
Inherited Initial Version
Yes top CSS2, 2.1

Example

This style rule positions all table captions below their parent tables:

caption {
  caption-side: bottom;
}

Try it yourself!View all demos

Description

This property sets the vertical position of a table caption box (an element whose display property has the value table-caption).

To affect the horizontal alignment of the caption text, use the text-align property.

The caption box is positioned relative to the table box. See Table Formatting for details.

Value

bottom
puts the caption below the table box
top
puts the caption above the table box

CSS2 also defined the values left and right for this property, but they were removed in CSS2.1.

Compatibility

IE5.5None
6.0None
7.0None
Firefox1.0Full
1.5Full
2.0Full
Safari1.3Full
2.0Full
3.0Full
Opera9.2Full
9.5Full

Internet Explorer for Windows versions up to and including 7 don’t support this property.

Related Reading

User-contributed notes

There are no comments yet.

Add a note

To post a note on this topic, please log in with your SitePoint username and password. If you don't have an account yet, you can create a new account for free.

Related Products

The Principles of Beautiful Web Design

Best Seller!

You don’t need to go to Art School to design great looking web sites!

Book Cover: The Principles of Beautiful Web Design

Download the FREE sample chapters