Are you a GenerateCustomer?

Do you have an active GP Premium or GenerateBlocks Pro license key?

Create a GenerateSupport account for GeneratePress and GenerateBlocks support in one dedicated place.

Create an account
Already have a GenerateSupport account? Login

Just browsing?

Feel free to browse the forums. Support for our free versions is provided on WordPress.org (GeneratePress, GenerateBlocks).

Want to become a premium user? Learn more below.

Table border properties

  • Hi,

    how can I edit table border properties? The menu options for this in a WordPress Block for tables are disabled/invisible, I assume GP does this.

    I need to use invisible table borders to force a layout mixed with text blocks and pictures.

    Thank you

  • Hi there,

    it will require CSS.
    Can you share a link to where i can see the table on your site ?

  • I sent a private link.

  • Hi Versite,

    Will all tables on your site have the same border color? If so, try adding this through Appearance > Customize > Additional CSS:

    .wp-block-table td {
        border: solid 1px #ff0000;
    }

    If you’re looking for different colors, add a custom class to your Table. Adding Custom Classes: https://wordpress.com/support/wordpress-editor/adding-additional-css-classes-to-blocks/

    Then, the code for that would be something like this:

    .YOUR-CUSTOM-CLASS td {
        border: solid 1px #ff0000;
    }
  • Hi Fernando,

    the code above gives me a 1px red border, which is not what I need. I need invisible borders, so I changed it to

    .wp-block-table td {
        border-width: 0px;}
    

    Still, there is a faint dotted line on the left and top side of the table.

    I get the same result (i.e. no invisible borders) with

    
    .wp-block-table td {
        border: none; }
    

    So I suspect that there is something else going on. The site uses a photo as a background so I cannot match the color to hide the borders.

  • Add this:

    .wp-block-table table {
        border: none;
    }
  • Hi Fernando,

    Thank you, adding both statements removes all borders.

    I would be nice to have the ability to edit table properties without custom CSS.

  • That’s a WordPress feature/Block. GP has no control over that.

    An alternative would be to use a GB Grid Block so you have control over the borders: https://docs.generateblocks.com/article/grid-overview/

  • When I use the default theme, I can edit the table properties in the block editor, with GP these options are not there. So my assumption was that is is related to GP.

    I will look into GB, can I do simple things like the one we are discussing with the free version?

  • Yes, that’s available in the free version.

    As for the border settings not showing in GP, you’re right. It’s excluded in GP for issues it can cause. See Tom’s explanation here: https://github.com/tomusborne/generatepress/issues/389

Viewing 10 posts - 1 through 10 (of 10 total)
  • You must be logged in to reply to this topic.