Table Shortcode

Shortcode Usage

[pre][table]
 
    [table_headers]
        [table_header]…[/table_header]
        [table_header]…[/table_header]
        [table_header]…[/table_header]
        …
    [/table_headers]
   
    [table_body]
        [table_row]
            [table_cell]…[/table_cell]
            [table_cell]…[/table_cell]
            …
        [/table_row]
        [table_row]
            [table_cell]…[/table_cell]
            [table_cell]…[/table_cell]
        [/table_row]
        …
    [/table_body]
   
[/table]
[/pre]

[infobox]

Important Note: the number of table_headers and number of table_cells MUST be equal.

Note: As usual, you can put a style attribute anywhere.

[/infobox]


Example

[table style=”width: 100%”]

[table_headers]
[table_header]Header 1[/table_header]
[table_header]Header 2[/table_header]
[table_header]Header 3[/table_header]
[/table_headers]

[table_body]
[table_row]
[table_cell]Cell 1-1[/table_cell]
[table_cell]Cell 1-2[/table_cell]
[table_cell]Cell 1-3[/table_cell]
[/table_row]
[table_row]
[table_cell]Cell 2-1[/table_cell]
[table_cell]Cell 2-2[/table_cell]
[table_cell]Cell 2-3[/table_cell]
[/table_row]
[/table_body]

[/table]