Error displaying table on product information page

This topic has 6 replies, 3 voices, and was last updated 11 months, 1 weeks ago ago by Andrew Mitchell

  • Avatar: anhph1
    anhph1
    Participant
    January 8, 2025 at 11:13

    The products posted on my website need to use a table to display the specifications. Initially the table is displayed without a border. I tried adding the following code to the additional CSS section of the Single Product Tab and it shows the border.

    table {
        border-collapse: collapse;
    }
    
    table, th, td {
        border: 1px solid #ddd;
        padding: 8px 5px;  /* 8px trên/dưới, 5px trái/phải */
        text-align: left;
    }
    
    th {
        background-color: #f4f4f4;
    }
    
    tr:nth-child(even) {
        background-color: #f9f9f9;
    }
    

    However the content cannot be left aligned, it always shows 2-aligned and is very difficult to read.
    I tried clearing the cache, tried following this topic (https://www.8theme.com/topic/the-table-style-is-not-right-please-have-a-look-upon-it/) but it didn’t work.
    Please let me know how to fix it.

    Files is visible for topic creator and
    support staff only.
    5 Answers
    Avatar: Justin
    Luca Rossi
    Support staff
    January 9, 2025 at 07:09

    Dear @anhph1,

    We hope this message finds you well.

    Could you kindly share with us the URL of the product that contains the tables? This will allow us to provide you with the necessary custom CSS codes.

    Thank you for your cooperation.

    Best regards,
    The 8Theme Team

    Avatar: anhph1
    anhph1
    Participant
    January 9, 2025 at 07:59

    I have removed all the additional Css so you can advise best. And here is the link for a product that is using tables.

    Please contact administrator
    for this information.
    Avatar: Justin
    Luca Rossi
    Support staff
    January 9, 2025 at 10:12

    Hi @anhph1,

    Please try adding this custom CSS under XStore > Theme Options > Theme Custom CSS > Global CSS:

    
    #tab-description table {
        border-collapse: collapse;
    }
    
    #tab-description table th,
    #tab-description table td {
        border: 1px solid #333;
        text-align: start;
        padding: 10px;
    }
    

    https://prnt.sc/1BZ3RmRs3LFn

    Kind regards,
    The 8Theme Team

    Avatar: anhph1
    anhph1
    Participant
    January 10, 2025 at 05:40

    Thank Luca Rossi. It worked!

    Avatar: Andrew Mitchell
    Andrew Mitchell
    Support staff
    January 10, 2025 at 05:40

    Dear anhph1,

    We trust our theme is enhancing your experience. Taking a brief moment to rate it with a glowing 5 stars on ThemeForest would be immensely appreciated. Your feedback holds significant value for us.

    Click here to rate now: https://themeforest.net/downloads

    Thank you sincerely for your ongoing support!

    Best Regards,
    The 8Theme Team

  • Viewing 6 results - 1 through 6 (of 6 total)

The issue related to '‘Error displaying table on product information page’' has been successfully resolved, and the topic is now closed for further responses

We're using our own and third-party cookies to improve your experience and our website. Keep on browsing to accept our cookie policy.