Tables

""

See Tables & Textboxes in the Pressbooks User Guide.

Issues to Note

Styling tables can be a challenge when the CSS of a book overrides the HTML for individual chapters. For help with this issue, see Customizing your Exports with Custom Styles in the Pressbooks User Guide.

Formats affected Feature Problem Work around
Webbook Table cells with more than one paragraph The first paragraph in each cell will have no extra space between lines. All additional paragraphs in the same cell will have extra space between the lines and the text will be larger. (Problem reported to WordPress.) You have two options:

  1. Go into the Text (HTML) editor and add a blank line after the opening <td> tag (this means pressing the [Enter] key twice) and saving the chapter while still in the Text (HTML) editor.
  2. Go into the Text (HTML) editor at encase each paragraph within a table cell in <p> tags. Save the chapter while still in the Text (HTML) editor.
All formats Table borders After an update on December 21, 2018, borders were stripped out of many tables. To fix a specific table, select all cells in the table. Click the Tables icon in the WYSIWYG toolbar, and click under “Cell” click “Table cell properties.” Under “Class” select “Border.”

To add a border around all table cells in your entire book, add the following to your Web, EPUB, and PDF Custom Styles (found under the Appearance tab in the Dashboard Menu):

.front-matter td, .part td, .chapter td, .back-matter td, body#tinymce.wp-editor td {
border: 1px solid;
border-color: #373d3f; }
.front-matter th, .part th, .chapter th, .back-matter th, body#tinymce.wp-editor th {
border: 1px solid;
border-color: #373d3f; }

The below video is from the Pressbooks Video Tutorial Series.

https://video.bccampus.ca/id/0_p62p6k1b?width=608&height=402&playerId=23448552

License

Icon for the Creative Commons Attribution 4.0 International License

NSCC Guide to Using PressbooksEDU by BCcampus is licensed under a Creative Commons Attribution 4.0 International License, except where otherwise noted.

Share This Book