• Resolved geckoroutes

    (@geckoroutes)


    Hi,

    I’m using this amazing plugin already for a while, but now I want to add some more CSS code. But unfortunately I can’t get it working.

    See here an example page with a table: https://wordpress-175698-743047.cloudwaysapps.com/vietnam/Hanoi-to-Ninh-Binh/

    .tablepress {
        border-spacing: 0 7px;
    }
    
    .tablepress th {
        padding: .4rem .5rem;
        background: #D59941;
        color: #FFFFFF;
    }
    
    .tablepress td {
        border: 1px solid #ccc;
        padding: .5rem;
        border-left: none;
        border-right: none;
    }
    
    .tablepress tr {
        border-bottom: 1px solid #ccc;
        border-top: 1px solid #ccc;
    }
    
    .tablepress td:nth-child(1) {
        border-left: 1px solid #ccc;
    }
    
    .tablepress td:nth-child(3) {
        border-right: 1px solid #ccc;
    }

    Hope anyone can offer me some help!

    Thanks!

    The page I need help with: [log in to see the link]

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author TobiasBg

    (@tobiasbg)

    Hi,

    thanks for your question, and sorry for the trouble.

    From what I can see on first glance, the border changes from this CSS are being applied. Or am I missing something? What exactly is not working?

    Regards,
    Tobias

    Thread Starter geckoroutes

    (@geckoroutes)

    If you copy paste the following code in this link, you can see the results I wish for (sorry I couldn’t include a PrintScreen)

    table{
      border-spacing: 0px 7px;
    }
    
    th{
      padding: 0.4rem 0.5rem;
      background: #D59941;
      color: #FFFFFF;
    }
    
    td {
      border: 1px solid #ccc;
      padding: 0.5rem;
      border-left: none;
      border-right: none;
    }
    
    tr {
        border-bottom: 1px solid #ccc;
        border-top: 1px solid #ccc;
    }
    
    td:nth-child(1){
      border-left: 1px solid #ccc;
    }
    
    td:nth-child(3){
      border-right: 1px solid #ccc;
    }

    The only change I made to the code, was adding .tablepress in front of each new rule.

    Plugin Author TobiasBg

    (@tobiasbg)

    Hi,

    so basically the background color and the spacing are not as expected?

    Can you please try again with this “Custom CSS”:?

    .tablepress {
    	border-spacing: 0 7px;
    	border-collapse: separate;
    }
    
    .tablepress th {
    	padding: .4rem .5rem;
    	background: #D59941 !important;
    	color: #FFFFFF;
    	border: none !important;
    }
    
    .tablepress td {
    	border-top: 1px solid #cccccc !important;
    	border-bottom: 1px solid #cccccc !important;
    }
    
    .tablepress tbody tr {
    	border: 1px solid #cccccc !important;
    }
    
    .tablepress td:nth-child(1) {
    	border-left: 1px solid #cccccc;
    }
    
    .tablepress td:nth-child(3) {
    	border-right: 1px solid #ccc;
    }

    Regards,
    Tobias

    Thread Starter geckoroutes

    (@geckoroutes)

    Thank you so much for this help! It works perfect now!

    Plugin Author TobiasBg

    (@tobiasbg)

    Hi,

    no problem, you are very welcome! ?? Good to hear that this helped!

    Best wishes,
    Tobias

    P.S.: In case you haven’t, please rate TablePress here in the plugin directory. Thanks!

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Custom css not loading’ is closed to new replies.