Title: HTML Tables with CSS Styles
Last modified: August 22, 2016

---

# HTML Tables with CSS Styles

 *  [meravjon](https://wordpress.org/support/users/meravjon/)
 * (@meravjon)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/html-tables-with-css-styles/)
 * Hi
    i tried using the css style sheet (child theme) to make a custom table:
 *     ```
       table.chem {
           font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;
           width: 100%;
           border-collapse: collapse;
       }
   
       table.chem td, table.chem th {
           font-size: 19px;
           border: 1px solid #062073;
           padding: 3px 7px 2px 7px;
       }
   
       table.chem th {
           font-size: 19px;
           text-align: left;
           padding-top: 5px;
           padding-bottom: 4px;
           background-color: #3a9ed1;
           color: #062073;
       }
   
       table.chem tr.alt td {
           color: #062073;
           background-color: #fafafa;
       }
       ```
   
 * then use html tag like:
    `<table class="chem">` but it doesn’t work’ can’t understand
   why

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

 *  [martcol](https://wordpress.org/support/users/hotmale/)
 * (@hotmale)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/html-tables-with-css-styles/#post-5772217)
 * Can you show a link to the page?
 * What doesn’t work exactly?
 *  Thread Starter [meravjon](https://wordpress.org/support/users/meravjon/)
 * (@meravjon)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/html-tables-with-css-styles/#post-5772232)
 * hi thanks for reply.
    the post is for mermbers only. In other posts i used tablepress
   and I’m trying to make them a like here is a link to other post. [](http://www.easy-chemistry.co.il/%d7%a8%d7%99%d7%9b%d7%95%d7%96%d7%99%d7%9d-%d7%a9%d7%9c-%d7%aa%d7%9e%d7%99%d7%a1%d7%95%d7%aa/)
 *  Thread Starter [meravjon](https://wordpress.org/support/users/meravjon/)
 * (@meravjon)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/html-tables-with-css-styles/#post-5772241)
 *  Thread Starter [meravjon](https://wordpress.org/support/users/meravjon/)
 * (@meravjon)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/html-tables-with-css-styles/#post-5772242)
 * [http://www.easy-chemistry.co.il/%D7%A8%D7%99%D7%9B%D7%95%D7%96%D7%99%D7%9D-%D7%A9%D7%9C-%D7%AA%D7%9E%D7%99%D7%A1%D7%95%D7%AA/](http://www.easy-chemistry.co.il/%D7%A8%D7%99%D7%9B%D7%95%D7%96%D7%99%D7%9D-%D7%A9%D7%9C-%D7%AA%D7%9E%D7%99%D7%A1%D7%95%D7%AA/)
 *  Thread Starter [meravjon](https://wordpress.org/support/users/meravjon/)
 * (@meravjon)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/html-tables-with-css-styles/#post-5772374)
 * Hi
    I tried a different approach so I used this in the css style sheet (child
   theme):
 *     ```
       table, td, th {
           border: 1px solid #062073;
       }
       tr:hover td {background:#8183d8}
       ```
   
 * That’s all good.
 * and then for the first line I used
    `<thead style="background-color: #3a9ed1;"
   >` but the first line did not change. somebody?

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

The topic ‘HTML Tables with CSS Styles’ is closed to new replies.

 * ![](https://i0.wp.com/themes.svn.wordpress.org/customizr/4.4.24/screenshot.png)
 * Customizr
 * [Support Threads](https://wordpress.org/support/theme/customizr/)
 * [Active Topics](https://wordpress.org/support/theme/customizr/active/)
 * [Unresolved Topics](https://wordpress.org/support/theme/customizr/unresolved/)
 * [Reviews](https://wordpress.org/support/theme/customizr/reviews/)

 * 5 replies
 * 2 participants
 * Last reply from: [meravjon](https://wordpress.org/support/users/meravjon/)
 * Last activity: [11 years, 3 months ago](https://wordpress.org/support/topic/html-tables-with-css-styles/#post-5772374)
 * Status: not resolved