Title: Custom CSS for table
Last modified: October 17, 2023

---

# Custom CSS for table

 *  Resolved [mweiser](https://wordpress.org/support/users/mweiser/)
 * (@mweiser)
 * [2 years, 7 months ago](https://wordpress.org/support/topic/custom-css-for-table/)
 * Hello,
 * Hello, I have about one hundred tables and need to hide the footer only when 
   filtering is enabled. Instead of a CSS rule for every single table like
 * `.wpDataTableID-140 tfoot {
   display: none;}
 * or even less specific
 * `.wpDataTable tfoot {
   display: none;}
 * Adding a custom class to each table would be more effective so I can add the 
   style to my master stylesheet.

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

 *  Plugin Author [wpDataTables](https://wordpress.org/support/users/wpdatatables/)
 * (@wpdatatables)
 * [2 years, 7 months ago](https://wordpress.org/support/topic/custom-css-for-table/#post-17135525)
 * Hello,
   To begin, I want to extend my heartfelt apologies for the delayed reply,
 * which is due to an unexpectedly high volume of inquiries.
 * We truly value your patience during this period.
   I am not sure if we understood
   your use-case fully.If you need to set a Conditional Logic that would trigger
   CSS to hide the Table footer only in case when some filtering is active,and to
   not trigger when there is no filtering, at this moment we do not have a solution
   for that, but advanced Column filters are not available in the Lite version, 
   so we presume you are a Premium user?
 * Since you’re using the Premium version of the plugin, please open a ticket on
   our [main Support platform here](https://tmsplugins.ticksy.com/),
 *  and one of our Agents will respond as quickly as possible.
 * Premium products are not supported in these forums, as per [this comment](https://wordpress.org/support/topic/error-when-not-logged-into-wordpress-backend/#post-15050671)
   by WordPress.org moderators.
 * Thank you for understanding. 
 * Kind regards.
 *  Thread Starter [mweiser](https://wordpress.org/support/users/mweiser/)
 * (@mweiser)
 * [2 years, 7 months ago](https://wordpress.org/support/topic/custom-css-for-table/#post-17136081)
 * Hi there,
 * My only question is if it is possible to add a custom class to a table using 
   the free version?
 * Thanks
    -  This reply was modified 2 years, 7 months ago by [mweiser](https://wordpress.org/support/users/mweiser/).
 *  Plugin Author [wpDataTables](https://wordpress.org/support/users/wpdatatables/)
 * (@wpdatatables)
 * [2 years, 7 months ago](https://wordpress.org/support/topic/custom-css-for-table/#post-17147080)
 * Hello,
   We apologise for a late reply to this.Yes, in the Free version you won’t
   have the “Customize” section for each Table in the Table settings, but you can
   add Custom Classes in any Table Column, then you can call that CSS class in the
   main Plugin settings/Custom JS and CSS/Custom CSS, and you can write any custom
   style you need there.–So any table that has that class added to any column will
   be applied.–If you wish to target a specific Table ID only, you can add the Table
   ID in your CSS code, exactly as you already did before :
 * .wpDataTableID-140 tfoot {
   display: none;}–So for each Table, then you would 
   need to add a new CSS line and target the Table ID like that.But we don’t understand
   what you mean when you say to add a Custom Class to a Table.You can add a class
   to any Column of a Table, in the Column’s Display Settings, but you can not add
   a Class to an entire Table’s HTML container if that is what you meant, or for
   example to add a Custom CSS Class to a footer of some Tables, etc.At the moment
   you can just add a Custom Class to a Column, or if you use an URL Column – you
   can add a class to a Button in that Column also with the built in Column settings.–
   We hope that helps to clarify the current capabilities.If you have an idea how
   we might improve that, you can make a development suggestion.Please feel free
   to search on our suggestions page ([https://features.wpdatatables.com/](https://features.wpdatatables.com/)),
   to see if someone may be already suggested this feature. If you can’t see it,
   feel free to add your suggestion there, and as more people vote, the feature 
   will move higher on the priority list. You can certainly follow our changeLog
   if you’d like([https://wordpress.org/plugins/wpdatatables/#developers](https://wordpress.org/plugins/wpdatatables/#developers)),
   where we state any changes/new features/bug fixes during updates; and our newsletter(
   [https://wpdatatables.com/newsletter/](https://wpdatatables.com/newsletter/)),
   so you’re informed about new features, bug fixes, freebies, etc.
 *  Thread Starter [mweiser](https://wordpress.org/support/users/mweiser/)
 * (@mweiser)
 * [2 years, 7 months ago](https://wordpress.org/support/topic/custom-css-for-table/#post-17147136)
 * I was hoping to add a class to a table such as
 *     ```wp-block-code
       <table class="custom-class">
       ```
   
 * so that I can target every table, regardless of table ID.
 *  Plugin Author [wpDataTables](https://wordpress.org/support/users/wpdatatables/)
 * (@wpdatatables)
 * [2 years, 7 months ago](https://wordpress.org/support/topic/custom-css-for-table/#post-17162057)
 * Hello,
   Thank you for that clarification. We presumed that you meant something
   like that.  At the moment, it is not possible with our current built-in features.
 * Right now, we can only add a custom CSS class to a Column directly, in each Column
   Display settings, and only other way is to add a class to a cell, row, or a column
   via our Conditional Formatting, which is not available in the free/Lite version,
   but other than that, it is not possible in free or Premium version to add a class
   to the entire Table.
   You can add a development suggestion as advised above and
   our devs will do their best to add this in the future.Best regards.

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

The topic ‘Custom CSS for table’ is closed to new replies.

 * ![](https://ps.w.org/wpdatatables/assets/icon-128x128.gif?rev=3010404)
 * [wpDataTables - WordPress Data Table, Dynamic Tables & Table Charts Plugin](https://wordpress.org/plugins/wpdatatables/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wpdatatables/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wpdatatables/)
 * [Active Topics](https://wordpress.org/support/plugin/wpdatatables/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wpdatatables/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wpdatatables/reviews/)

 * 6 replies
 * 2 participants
 * Last reply from: [wpDataTables](https://wordpress.org/support/users/wpdatatables/)
 * Last activity: [2 years, 7 months ago](https://wordpress.org/support/topic/custom-css-for-table/#post-17162057)
 * Status: resolved