• Resolved hellothereman

    (@hellothereman)


    Hello,

    I’m planning to upload many different tables of different sizes in bulk.

    I noticed that it’s turned on by default for every new table. I don’t need the first row of the table to be the table header.

    TablePress Default Settings:

    View post on imgur.com

    I would like it to be turned off for every new table by default – is there any chance to change the settings?

    The Desired Result:

    View post on imgur.com

    I already used this plugin to turn off the javascript for all the new tables:

    https://tablepress.org/extensions/datatables-off-new-tables/

    It’s great that I found it, because I used to turn it off manually in the past. That plugin alone saves me so much time, so thank you!

    I read this thread that I believe is related to my question. I don’t think it will work for me because the tables I’m about to upload have different number of rows and columns:

    https://wordpress.org/support/topic/default-settings-for-the-table/

    >To change the default settings for all new tables, you’d have to use a bit of programming code and adjust a filter hook

    I’m not really a programmer, but could you elaborate a bit?

    Thank you! 🙂

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

    (@tobiasbg)

    Hi,

    thanks for your post, and sorry for the trouble.

    The TablePress Extension to turn off DataTables for new tables will indeed be useful here! You can modify it to also turn off the Table Head checkbox by default, for all new tables. For that, just modify the file /wp-content/plugins/tablepress-datatables-off-new-tables/tablepress-datatables-off-new-tables.php on your server and insert this line:

    $table['options']['table_head'] = false;
    

    right below the line

    $table['options']['use_datatables'] = false;
    

    Regards,
    Tobias

    Thread Starter hellothereman

    (@hellothereman)

    You’re doing so much good here.

    It worked like a charm.

    Thank you, Tobias!

    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 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Turn The Table Header Off By Default’ is closed to new replies.