1. Home
  2. Knowledge Base
  3. WooCommerce Product Table
  4. Advanced Usage
  5. How do I change the alignment of the product table’s contents?

How do I change the alignment of the product table’s contents?

WooCommerce Product Table aligns all content to the left, which works fine for most tables.

There’s currently no built-in option to change the alignment, for example to center the text in the table. You can achieve this using simple CSS. You can add the following to your theme’s stylesheet or in the Customizer (see Appearance -> Customize -> Custom CSS):

Center Alignment:

.wc-product-table th, .wc-product-table td {
    text-align: center;
}

Right Alignment:

.wc-product-table th, .wc-product-table td {
    text-align: right;
}

If you need any help with this then we recommend posting a job on Codeable, where pre-approved WordPress experts will bid for the work. Alternatively, you can use our styling and customisations service – please contact us for a quote.

Was this article helpful?

Related Articles