Title: Table Borders
Last modified: December 23, 2017

---

# Table Borders

 *  Resolved [IMTanuki](https://wordpress.org/support/users/imtanuki/)
 * (@imtanuki)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/table-borders-12/)
 * Hi
 * Trying to create a border around a table (no internal cell borders). I think 
   I’m close, but can’t seem to gt the right side border to work…
 *     ```
       .tablepress thead th:first-of-type
       	{
       	border-left: 1px solid #9476c9;
       	border-top: 1px solid #9476c9;
       	}
   
       .tablepress thead th:last-of-type
       	{
       	border-right: 1px solid #9476c9;
       	border-top: 1px solid #9476c9;
       	}
   
       .tablepress tbody tr
       	{
       	border-collapse: collapse;
       	border: 1px solid #9476c9;  /* NOT SURE THIS IS CORRECT OR SUFFICIENT
       	}
       ```
   
 * _[Moderator note: code fixed. Please wrap code in the backtick character or [use the code button](https://make.wordpress.org/support/handbook/forum-welcome/#post-code-safely).]_
 * Has anyone tried to do this?
 * Thanks!
    -  This topic was modified 8 years, 5 months ago by [bdbrown](https://wordpress.org/support/users/bdbrown/).

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

 *  Plugin Author [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * (@tobiasbg)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/table-borders-12/#post-9808060)
 * 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 [IMTanuki](https://wordpress.org/support/users/imtanuki/)
 * (@imtanuki)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/table-borders-12/#post-9808607)
 * Tobias,
 * Thanks for the quick reply.
 * Try url: [http://dev03.altchinese.com/](http://dev03.altchinese.com/)
 * I may make some changes, but in general, I think my syntax for the right side
   of the table may be off:
 * – the table header is fine (but that is a single row)
    – not sure if there is
   a special css reference to ALL rows in the table body…?
 * Regards!
 *  Plugin Author [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * (@tobiasbg)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/table-borders-12/#post-9808635)
 * Hi,
 * thanks for the link!
 * Now, from what I understand, you just want a border around the table. Why don’t
   you just use
 *     ```
       .tablepress {
         border: 1px solid #9476c9;
       }
       ```
   
 * then? That should be the shortest version.
 * Regards,
    Tobias
 *  Thread Starter [IMTanuki](https://wordpress.org/support/users/imtanuki/)
 * (@imtanuki)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/table-borders-12/#post-9808998)
 * Nope.
 * I’m using Visual Composer and I thought there might be a conflict with tablepress
   and columns or custom boxes, so I put it in a single row…still no right border…:
   >(
 *  Thread Starter [IMTanuki](https://wordpress.org/support/users/imtanuki/)
 * (@imtanuki)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/table-borders-12/#post-9809007)
 * with
 * .tablepress {
    border: 1px solid #9476c9 !Important; }
 * I get the top, left, bottom borders. But not the right.
 * a) Do you know of any conflict with Visual Composer?
    b) Do you know of any explicit
   CSS for the right side of the table, including header and data rows?
 * Thanks!
 *  Thread Starter [IMTanuki](https://wordpress.org/support/users/imtanuki/)
 * (@imtanuki)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/table-borders-12/#post-9809016)
 * And…with the single border command, the bottom border does not display.
 * I’m pullin my hair out…
 *  Thread Starter [IMTanuki](https://wordpress.org/support/users/imtanuki/)
 * (@imtanuki)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/table-borders-12/#post-9809056)
 * FWIW, here’s what finally worked:
 * for desktops:
 *  border-top: 1px solid #b3b3b3 !Important;
    border-bottom: 1px solid #b3b3b3 !
   Important; border-left: 1px solid #b3b3b3 !Important; border-right: 2px solid#
   b3b3b3 !Important;
 * for mobile:
 *  border-top: 1px solid #b3b3b3 !Important;
    border-bottom: 4px solid #b3b3b3 !
   Important; border-left: 1px solid #b3b3b3 !Important; border-right: 2px solid#
   b3b3b3 !Important;
 * Not sure what the problem is…
 *  Plugin Author [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * (@tobiasbg)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/table-borders-12/#post-9809436)
 * Hi,
 * that’s indeed a bit strange… Your theme’s CSS code be interfering, I guess.
    
   Good to hear that you were able to make it work 🙂
 * Best wishes,
    Tobias

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

The topic ‘Table Borders’ 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/)

 * 8 replies
 * 2 participants
 * Last reply from: [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * Last activity: [8 years, 5 months ago](https://wordpress.org/support/topic/table-borders-12/#post-9809436)
 * Status: resolved