WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Adding extra table class (8 posts)

  1. Fleiding
    Member
    Posted 1 year ago #

    Hi there,

    I am using the wonderful Yoko-theme for my website and I am very happy with it.

    The only thing what is bothering me are the table borders. I edited the CSS to show no borders in posts and pages. Works great, but now there is a situation which requires me to have a table with borders.

    If i but the normal CSS back, all my tables will have borders, but I do not want that. Only a few tables should have borders.

    I have tried copying this piece of code (for all the tables) and replaced the word content with my own word. Used <table class="word"> to summon the custom table style.

    /* --- Post Tables --- */
    #content table {
    	margin:10px 0px 30px 0px;
    }
    #content table thead {
    	border-top:0px solid #ddd;
    }
    #content table tr {
    	border-bottom:0px solid #ddd;
    }
    #content table tr th {
    	padding: 10px 20px 10px 20px;
    	border-top:0px solid #ddd;
    	border-left:0px solid #ddd;
    	border-right:0px solid #ddd;
    }
    #content table tr td {
    	padding: 10px 20px 10px 20px;
    	border-left:0px solid #ddd;
    	border-right:0px solid #ddd;
    }
  2. Andrew Nevins
    Barrel Rider, Spam Zapper & Volunteer Moderator
    Posted 1 year ago #

    Do you want only tables on a particular page to be styled?

  3. Fleiding
    Member
    Posted 1 year ago #

    A few pages.

  4. Andrew Nevins
    Barrel Rider, Spam Zapper & Volunteer Moderator
    Posted 1 year ago #

    Which table(s) do you want styled?

  5. Fleiding
    Member
    Posted 1 year ago #

    I am currently writing a few new articles in which I need the borders.

  6. Andrew Nevins
    Barrel Rider, Spam Zapper & Volunteer Moderator
    Posted 1 year ago #

    Are there tables in articles that you don't need borders on?

  7. Fleiding
    Member
    Posted 1 year ago #

    Yes, but in all the articles I need borders there are no tables without borders.

    So:

    page1: no borders on all tables
    page2: no borders on all tables
    page3: borders on all tables

  8. Fleiding
    Member
    Posted 1 year ago #

    Resolved it with this plugin:

    http://wordpress.org/extend/plugins/tablepress/

Topic Closed

This topic has been closed to new replies.

About this Topic