• Resolved stevegayler

    (@stevegayler)


    Hi Tobias,
    The plugin is working brilliantly for our project on our website.
    We currently have about 45 different tables containing in excess of 10,00 lines of data.

    Essentially we have 4 different table types and need to set options for each to force column widths and formatting.

    Unfortuantely we have noticed there is a lot of option code appearing in the header of each page of our html markup.

    Is there a way of setting a format once for each table type, or at least assigning the same code to different table ID’s. This is 1 example here currently set for table ID 495, but would be the same for about 25 table ID’s.

    Any help much appreciated!

    Cheers

    .wp-table-reloaded-id-495 td {font-family: Tahoma; font-size: 12px; color: #800000;} .column-1 {width: 40px;}.column-2 {width: 150px;}.column-3 {width: 140px;}.column-4 {width: 160px;}.column-5 {width: 40px;}.column-6 {width: 200px;}.column-7 {width: 100px;}

    https://www.ads-software.com/extend/plugins/wp-table-reloaded/

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

    (@tobiasbg)

    Hi,

    yes, this is possible, with an “Extra CSS class”. You would need one for each of your four different table types, like table-type-1, table-type-2, table-type-3, and table-type-4, or whatever you want.
    Then assign one such class to each of your 45 tables (by entering into the “Extra CSS class” field on the table’s “Edit” screen).
    Now, you can use this in the CSS, instead of having to use the entire list of classes with tables IDs in them. Does that explanation make sense?
    (You can also find an example here: https://www.ads-software.com/support/topic/plugin-wp-table-reloaded-what-css-to-put-to-change-the-backround-color-of-all-tables )

    Regards,
    Tobias

    Thread Starter stevegayler

    (@stevegayler)

    Thanks for your reply below.

    I’ve tried replacing the code with the following

    .wp-table-reloaded-id-styling-gigography td {font-family: Tahoma; font-size:
    12px; color: #800000;} .column-1 {width: 50px;} .column-2 {width: 100px;}
    .column-3 {width: 150px;} .column-4 {width: 230px;} .column-5 {width:
    220px;} .column-6 {width: 100px;}
    Here’s a page that it should be working on

    https://www.eurythmics.me.uk/eurythmics-revenge/

    This was the original I had for each table was the following except they all had !important after them.

    .wp-table-reloaded-id-styling-gigography td {font-family: Tahoma;
    font-size: 12px; color: #800000;} .column-1 {width: 50px;} .column-2 {width:
    100px;} .column-3 {width: 150px;} .column-4 {width: 230px;} .column-5
    {width: 220px;} .column-6 {width: 100px;}

    And ive left that one in so you can see it working on this page

    https://www.eurythmics.me.uk/annie-lennox-sacred-love-with-sting/

    To confirm I have also added .wp-table-reloaded-id-styling-gigography into the custom commands sections of both the pages.

    Let me know if you can see something stupidly obvious I have done!

    Plugin Author TobiasBg

    (@tobiasbg)

    Hi,

    first: Please remove .wp-table-reloaded-id-styling-gigography from the “Custom Commands” field again. The entry wp-table-reloaded-styling-gigography (yes, without the dot) in “Extra CSS classes” is enough.

    Now, you will need to adjust the CSS code. The main selector needs to be part of each command. Also, the “id-” part is too much. Please try

    .wp-table-reloaded-styling-gigography td {font-family: Tahoma; font-size: 12px; color: #800000;}
    .wp-table-reloaded-styling-gigography .column-1 {width: 50px;}
    .wp-table-reloaded-styling-gigography .column-2 {width: 100px;}
    .wp-table-reloaded-styling-gigography .column-3 {width: 150px;}
    .wp-table-reloaded-styling-gigography .column-4 {width: 230px;}
    .wp-table-reloaded-styling-gigography .column-5 {width: 220px;}
    .wp-table-reloaded-styling-gigography .column-6 {width: 100px;}

    Regards,
    Tobias

    Thread Starter stevegayler

    (@stevegayler)

    Tobias,

    You are a star once again. Thank you so much.

    I think you’ve just saved me about 400 lines of code!

    Cheers

    Plugin Author TobiasBg

    (@tobiasbg)

    Hi,

    awesome! ?? Great to hear that this did the trick! ??

    Best wishes,
    Tobias

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘[Plugin: WP-Table Reloaded] Formatting Multiple Tables’ is closed to new replies.