Private archive copy · Unofficial site · Content copyright belongs to Runoob Tutorial and the original authors · View Original

HTML caption align attribute

HTML align attribute

HTML caption Tag Reference HTML Tag

Example

A table with an element aligned to the bottom:

 

 

   

   

 

 

   

   

 

My savings
Month Savings
January $100

Try it »


Browser support

Internet Explorer Firefox Opera Google Chrome Safari

All major browsers support the align attribute.

Note:


Definition and Usage

HTML5 does not support the align attribute. Please use CSS instead.

The align attribute was deprecated in HTML 4.01.

The align attribute specifies the alignment of the caption element.

This attribute aligns the caption as a block element to the left, right, top, or bottom of the table.


Compatibility notes

HTML5 does not support the align attribute. Please use CSS instead.

CSS syntax: or

CSS example: position the table caption

In our CSS tutorial, you can find more details aboutcaption-side Details of the attribute.


Syntax

Attribute values

Value Description
left The caption is on the left of the table.
right The caption is on the right of the table.
top The caption is at the top of the table.
bottom The caption is at the bottom of the table.

HTML caption Tag Reference HTML Tag