• Resolved Boldt

    (@enso)


    Is there a way to change the table title tag from h2 to h3, h4, etc. (other than filtering the entire content? Perhaps a TablePress-specific filter hook that I’m missing?

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

    (@tobiasbg)

    Hi,

    thanks for your question, and sorry for the trouble.

    Yes, there’s indeed a filter hook for this, e.g.

    add_filter( 'tablepress_print_name_html_tag', 'boldt_tablepress_change_table_name_h2_to_h4', 10, 2 );
    function boldt_tablepress_change_table_name_h2_to_h4( $tag, $table_id ) {
      $tag = 'h4';
      return $tag;
    }

    Regards,
    Tobias

    Thread Starter Boldt

    (@enso)

    Thanks, and no trouble. Great plugin. I started digging into the code and found that filter. I was going to try it out but you saved me the time.

    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 ‘Change Table Title HTML Tag’ is closed to new replies.