• Resolved ltamm

    (@ltamm)


    I have 2 tables on 2 different pages. The both have the same CSS formating (with different id). Why do the headers look different?

    .tablepress-id-17,
    .tablepress-id-17 tr,
    .tablepress-id-17 thead th,
    .tablepress-id-17 tbody td {
    border: none !important;
    }
    .tablepress-id-17 .column-1 {
    padding: 4px;
    text-align: center;
    }
    .tablepress-id-17 .column-2 {
    padding: 4px;
    }
    .tablepress-id-17 .column-3 {
    padding: 4px;
    }
    .tablepress-id-17 .column-4 {
    padding: 4px;
    }
    .tablepress-id-17 .column-5 {
    padding: 4px;
    text-align: center;
    }
    .tablepress-id-17 .column-6 {
    padding: 4px;
    text-align: center;
    }
    .tablepress-id-17 thead th {
    font-family: myriad pro;
    font-size: 14px;
    }
    .tablepress-id-17 tbody td {
    font-family: myriad pro;
    font-size: 14px;
    }

    The page I need help with: [log in to see the link]

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

    (@tobiasbg)

    Hi,

    thanks for your post, and sorry for the trouble.

    The reason for this is that one table has more columns and those then don’t get the reduced padding.

    All in all, if we shorten your CSS, it should achieve the desired styling in both tables:

    .tablepress-id-17,
    .tablepress-id-17 tr,
    .tablepress-id-17 thead th,
    .tablepress-id-17 tbody td {
      border: none !important;
      font-family: myriad pro;
      font-size: 14px;
      padding: 4px;
      text-align: center;
    }
    

    Regards,
    Tobias

    Thread Starter ltamm

    (@ltamm)

    Thank you so much, but if I only wanted col 1 and 6 centered, do I have to add text-align for every column in the table?

    Plugin Author TobiasBg

    (@tobiasbg)

    Hi,

    ok, in that case, we’ll do the centering with the old code:

    .tablepress-id-17,
    .tablepress-id-17 tr,
    .tablepress-id-17 thead th,
    .tablepress-id-17 tbody td {
      border: none !important;
      font-family: myriad pro;
      font-size: 14px;
      padding: 4px;
    }
    .tablepress-id-17 .column-1,
    .tablepress-id-17 .column-2,
    .tablepress-id-17 .column-3,
    .tablepress-id-17 .column-4,
    .tablepress-id-17 .column-5,
    .tablepress-id-17 .column-6 {
      text-align: center;
    }
    

    Regards,
    Tobias

    Thread Starter ltamm

    (@ltamm)

    Perfect! Thanks!

    Plugin Author TobiasBg

    (@tobiasbg)

    Hi,

    no problem, you are very welcome! 🙂 Good to hear that this helped!

    Best wishes,
    Tobias

    P.S.: In case you haven’t, please rate TablePress here in the plugin directory. Thanks!

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘The look of the header’ is closed to new replies.