• Resolved Jajabingz

    (@ferryavb)


    Hi Tobias,

    Am trying to create a certain formatting but it is not working, can you please help me out? For all columns in a table 4, I would like to centralize their text. However, for the last row of table 4, I would like it to be left aligned because the entire row is merged. This is the below code which I have tried. Thank you.

    .tablepress-id-4 .column-1,
    .column-2,
    .column-3,
    .column-4,
    .column-5,
    .column-6,
    .column-7,
    .column-8 {
    	text-align: center;
    }
    
    .tablepress-id-4 .row-5 {
    	text-align: left;
    }
    • This topic was modified 7 years, 6 months ago by Jajabingz.
Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Tobias Bäthge

    (@tobiasbg)

    Hi,

    thanks for your post, and sorry for the trouble.

    The best CSS for this is:

    .tablepress-id-4 thead th,
    .tablepress-id-4 tbody td {
      text-align: center;
    }
    .tablepress-id-4 .row-5 td {
    	text-align: left;
    }

    (Note that your CSS would also work, but you must add the .tablepress-id-4 part to every line of selectors!)

    Regards,
    Tobias

    Thread Starter Jajabingz

    (@ferryavb)

    That worked! Many thanks Tobias.

    Plugin Author Tobias Bäthge

    (@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 3 replies - 1 through 3 (of 3 total)

The topic ‘CSS not working’ is closed to new replies.