• Resolved John

    (@dsl225)


    Hello,

    I tried many snippets but none was really centering the text in given rows, like:

    .tablepress .row-1 td {
    text-align: center;
    }

    .tablepress-id-8 .row-1 {
    text-align: center;
    }

    .tablepress .row-1 {
    text-align: center;
    }

    I need to center either the first 2 rows of a given table or all cells of that same table, in order to test and see how it looks like.

    I checked your documentation but really unable the correct code.

    Thanks!

Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter John

    (@dsl225)

    OK found out:

    .tablepress-id-123 td, .tablepress-id-123 th { text-align: center; }
    Plugin Author Tobias Bäthge

    (@tobiasbg)

    Hi!

    Thanks for your post and sorry for the trouble!

    From what I can see, you are trying to center the first table row here. If that is marked as the “Table Header”, please use this CSS code:

    .tablepress thead th {
    text-align: center;
    }

    If that doesn’t yet help, please post a link to the page with the table where this problem happens, so that I can take a direct look. Thanks!

    Best wishes,
    Tobias

    Thread Starter John

    (@dsl225)

    Thanks a lot, yes I changed my mind and centered all cells with my previous code.

    All good!

    Plugin Author Tobias Bäthge

    (@tobiasbg)

    Hi John,

    ah, I hadn’t noticed that reply yet 🙂 Great to hear that you already found a solution!

    Best wishes,
    Tobias

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Centering text in rows’ is closed to new replies.