| # | First Name | Last Name | Username |
|---|---|---|---|
| 1 | Mark | Otto | @mdo |
| 2 | Jacob | Thornton | @fat |
| 3 | Larry | the Bird |
You can inverse the color of the entire table by adding class table-inverse to the <table></table> element.
| # | First Name | Last Name | Username |
|---|---|---|---|
| 1 | Mark | Otto | @mdo |
| 2 | Jacob | Thornton | @fat |
| 3 | Larry | the Bird |
You can add inverse color to the table's column heading by adding the class thead-inverse to the <thead></thead> element.
| # | First Name | Last Name | Username |
|---|---|---|---|
| 1 | Mark | Otto | @mdo |
| 2 | Jacob | Thornton | @fat |
| 3 | Larry | the Bird |
Or alternatively, you can add a dark gray color to the table's column heading by adding the class thead-default to the <thead></thead> element.
| # | First Name | Last Name | Username |
|---|---|---|---|
| 1 | Mark | Otto | @mdo |
| 2 | Jacob | Thornton | @fat |
| 3 | Larry | the Bird |
You can add zebra striping to any table rows by adding the class table-striped to the <table></table> element.
| # | First Name | Last Name | Username |
|---|---|---|---|
| 1 | Mark | Otto | @mdo |
| 2 | Jacob | Thornton | @fat |
| 3 | Larry | the Bird |
You can add a border on all sides of the table and cells by adding the class table-bordered to the <table></table> element.
| # | First Name | Last Name | Username |
|---|---|---|---|
| 1 | Mark | Otto | @mdo |
| 2 | Jacob | Thornton | @fat |
| 3 | Larry | the Bird |
You can add a hover state on table tows by adding the class table-hover to the <table></table> element.
| # | First Name | Last Name | Username |
|---|---|---|---|
| 1 | Mark | Otto | @mdo |
| 2 | Jacob | Thornton | @fat |
| 3 | Larry | the Bird |
You can make tables more compact vertically by cutting cell padding in half by adding class table-sm to the <table></table> element.
| # | First Name | Last Name | Username |
|---|---|---|---|
| 1 | Mark | Otto | @mdo |
| 2 | Jacob | Thornton | @fat |
| 3 | Larry | the Bird |
You can color table rows by adding the following contextual classes to the <tr></tr>
And/or, color table cells by adding the following contextual classes to the <td></td>
| # | First Name | Last Name | Username |
|---|---|---|---|
| 1 | Mark | Otto | @mdo |
| 2 | Jacob | Thornton | @fat |
| 3 | Larry | the Bird | |
| 4 | Isiah | Thomas | @tommy |
| 5 | Michael | Jordon | @air |
You can make tables scroll horizontally on small devices by wrapping any table inside a div with class table-responsive.
| # | First Name | Last Name | Username | First Name | Last Name | Username |
|---|---|---|---|---|---|---|
| 1 | Mark | Otto | @mdo | Mark | Otto | @mdo |
| 2 | Jacob | Thornton | @fat | Mark | Otto | @mdo |
| 3 | Larry | the Bird | Mark | Otto | @mdo | |
| 4 | Mark | Otto | @mdo | Mark | Otto | @mdo |
| 5 | Jacob | Thornton | @fat | Mark | Otto | @mdo |
| 6 | Larry | the Bird | Mark | Otto | @mdo | |
| 7 | Mark | Otto | @mdo | Mark | Otto | @mdo |
| 8 | Jacob | Thornton | @fat | Mark | Otto | @mdo |
| 9 | Larry | the Bird | Mark | Otto | @mdo | |
| 10 | Jacob | Thornton | @fat | Mark | Otto | @mdo |
| 11 | Larry | the Bird | Mark | Otto | @mdo | |
| 12 | Mark | Otto | @mdo | Mark | Otto | @mdo |
| 13 | Larry | the Bird | Mark | Otto | @mdo |