Title: text center
Last modified: December 31, 2016

---

# text center

 *  Resolved [black82](https://wordpress.org/support/users/black82/)
 * (@black82)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/text-center-2/)
 * hello
 * i want to center the text in all fields. but i doesnt work. how can i do that?

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

 *  Plugin Author [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * (@tobiasbg)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/text-center-2/#post-8605948)
 * 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 [black82](https://wordpress.org/support/users/black82/)
 * (@black82)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/text-center-2/#post-8605980)
 * hello this site is offline at this time because it is not finished yet.
 *  Plugin Author [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * (@tobiasbg)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/text-center-2/#post-8605990)
 * Hi,
 * ok, then what did you try to center the text?
 * Usually, some “Custom CSS” like
 *     ```
       .tablepress-id-123 tbody td {
         text-align: center;
       }
       ```
   
 * is sufficient.
 * Regards,
    Tobias
 *  Thread Starter [black82](https://wordpress.org/support/users/black82/)
 * (@black82)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/text-center-2/#post-8607155)
 * hello
 * i tryed this custom css of you, but it doesn’t work
 * Why you can not select cell alignment when creating the table. this would be 
   better then always change the costum css.
 * how can i change the background colour of one cell?
 *  Plugin Author [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * (@tobiasbg)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/text-center-2/#post-8607215)
 * Hi,
 * the reason why such things have to be done with CSS code is that this is much
   more flexible than any user interface would ever be.
    For example, changing the
   background color is also very easy with CSS code. For an example, see [https://tablepress.org/faq/highlight-cells-or-content/](https://tablepress.org/faq/highlight-cells-or-content/)
 * In order to find out why the code for centering is not working for you, I’ll 
   need to take a look at the site. Can you somehow bring it online, at least as
   a test site?
 * Regards,
    Tobias
 *  Thread Starter [black82](https://wordpress.org/support/users/black82/)
 * (@black82)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/text-center-2/#post-8607269)
 * this code will be center the body, my first line is headupline and this is not
   center.
 * .tablepress-id- how can i take id 1 till 7 in one code
 *  Plugin Author [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * (@tobiasbg)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/text-center-2/#post-8607337)
 * Hi,
 * to center the header row as well, just extend the code to
 *     ```
       .tablepress-id-123 thead th,
       .tablepress-id-123 tbody td {
         text-align: center;
       }
       ```
   
 * For multiple tables, it would have to look like
 *     ```
       .tablepress-id-1 thead th,
       .tablepress-id-1 tbody td,
       .tablepress-id-2 thead th,
       .tablepress-id-2 tbody td,
       .tablepress-id-3 thead th,
       .tablepress-id-3 tbody td {
         text-align: center;
       }
       ```
   
 * and so on.
    Alternatively, you could make this the default setting for all TablePress
   tables with a shorter version:
 *     ```
       .tablepress thead th,
       .tablepress tbody td {
         text-align: center;
       }
       ```
   
 * Regards,
    Tobias
    -  This reply was modified 9 years, 4 months ago by [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/).

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

The topic ‘text center’ is closed to new replies.

 * ![](https://ps.w.org/tablepress/assets/icon.svg?rev=3192944)
 * [TablePress - Tables in WordPress made easy](https://wordpress.org/plugins/tablepress/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/tablepress/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/tablepress/)
 * [Active Topics](https://wordpress.org/support/plugin/tablepress/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/tablepress/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/tablepress/reviews/)

 * 7 replies
 * 2 participants
 * Last reply from: [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * Last activity: [9 years, 4 months ago](https://wordpress.org/support/topic/text-center-2/#post-8607337)
 * Status: resolved