English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية

HTML Reference Manual

Comprehensive HTML Tag List

HTML tbody charoff Attribute

The charoff attribute of HTML tbody sets the number of characters from which the content inside the <tbody> element starts to align, and it can only be used when the char attribute is specified and the align attribute is set to 'char'.

 HTML <tbody> tag

Online Example

Align the content inside the <tbody> element two characters to the right of the character ".":

<table border="1">
  <tr>
      <th>Program Language Books</th>
      <th>Price</th>
  </tr>
  <tbody align="char" char="." charoff="2">
    <tr>
      <td>PHP Basic Tutorial</td>
      <td>$50</td>
    </tr>
    <tr>
      <td>JAVA Programming Ideas</td>
      <td>$80</td>
    </tr>
  </tbody>
</table>
Test and see ‹/›

Browser Compatibility

IEFirefoxOperaChromeSafari

Note:Almost all mainstream browsers do not support the charoff attribute.

Definition and Usage

HTML5 The charoff attribute is not supported for <tbody>.

The charoff attribute sets the number of characters from the character specified by the char attribute with which the content within the <tbody> element is aligned.

The charoff attribute can only be used when the char attribute is specified and the align attribute is set to 'char'.

Syntax

<tbody charoff="number">

Attribute value

ValueDescription
numberSpecify the alignment method.
Positive numbers specify right alignment for the directional character.
Negative numbers specify left alignment for the directional character.
 HTML <tbody> tag