Viewing 15 replies - 1 through 15 (of 44 total)
  • Plugin Author TobiasBg

    (@tobiasbg)

    Hi,

    thanks for your post, and sorry for the trouble.

    Can you please post a link to the page with the table where this problem happens, so that I can take a direct look? Thanks!

    Regards,
    Tobias

    Thread Starter Katie Jane Collins

    (@katie-jane-collins)

    http://katiejanecollins.com/wp-admin/post.php

    It’s not a live post yet – so hopefully you can see the link as it’s on “preview” mode!

    Thanks
    Katie

    Plugin Author TobiasBg

    (@tobiasbg)

    Hi Katie,

    no, sorry, that link won’t work. It has to be a published post/page, as a non-logged-in user can not view the “Edit” screen of a post or its preview.

    Regards,
    Tobias

    Thread Starter Katie Jane Collins

    (@katie-jane-collins)

    http://katiejanecollins.com/fruit-infused-water

    I’ve randomly added it into an old post – see above.

    Thanks.

    Plugin Author TobiasBg

    (@tobiasbg)

    Hi,

    thanks! One reason for this might be that the use of the DataTables JS library is turned on, while its individual features are turned off.
    Can you therefore please try again after turning off the “Use DataTables” checkbox on the “Edit” screen of this table?

    Regards,
    Tobias

    Thread Starter Katie Jane Collins

    (@katie-jane-collins)

    Hi,

    It doesn’t seem to be making any difference.

    Thanks
    Katie

    Plugin Author TobiasBg

    (@tobiasbg)

    Hi Katie,

    thanks! Now I see what’s happening. Basically, your theme is giving non-text items (like big images or tables) a bigger width than the text. It does so by adding a margin to the text paragraphs.
    If you want, you can do the same to tables, by adding this to the “Custom CSS” textarea on the “Plugin Options” screen of TablePress:

    .tablepress {
      max-width: 1024px;
      margin: 0 auto;
    }

    Regards,
    Tobias

    Thread Starter Katie Jane Collins

    (@katie-jane-collins)

    Ah you’re a star, thank you!

    Is there a way or reducing the row width too? And also changing the colour of the header bar?

    Thanks

    Plugin Author TobiasBg

    (@tobiasbg)

    Hi,

    “row width”? Isn’t that the same as the table width? Can you maybe clarify what you mean with that?

    For the table head row background color, please see https://tablepress.org/faq/change-background-color-table-head-row/

    Regards,
    Tobias

    Thread Starter Katie Jane Collins

    (@katie-jane-collins)

    Hi,

    Sorry I should of said row height! (I.e. above and below the text – between each separation line).

    Thanks

    Plugin Author TobiasBg

    (@tobiasbg)

    Hi,

    ah, ok πŸ™‚ To reduce that, you can reduce the padding (inner white space) in the table cells, e.g. with

    .tablepress th,
    .tablepress td {
      padding: 4px;
    }

    In my opinion, this is not really necessary for your tables, though, as it would only reduce readability.

    Regards,
    Tobias

    Thread Starter Katie Jane Collins

    (@katie-jane-collins)

    Thank you!

    Is there any way to center the text too?

    Thanks

    Plugin Author TobiasBg

    (@tobiasbg)

    Hi,

    sure, by e.g. extending that code to

    .tablepress th,
    .tablepress td {
      padding: 4px;
      text-align: center;
    }

    Regards,
    Tobias

    Thread Starter Katie Jane Collins

    (@katie-jane-collins)

    Thank you!!

    Last but not least… is there a way to get separation lines in between each column?

    Thanks

    Plugin Author TobiasBg

    (@tobiasbg)

    Hi,

    another change to

    .tablepress th,
    .tablepress td {
      padding: 4px;
      text-align: center;
      border: 1px solid #cccccc;
    }

    should work, but similarly to narrow rows, they are seen to be reducing readability.

    Regards,
    Tobias

Viewing 15 replies - 1 through 15 (of 44 total)
  • The topic ‘Table Width’ is closed to new replies.