Site logo

[Resolved] How to change the default H2 tag widget to H3 tags

Home Forums Support [Resolved] How to change the default H2 tag widget to H3 tags

Home Forums Support How to change the default H2 tag widget to H3 tags

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #1151822
    phan cong tai

    How to change the default H2 tag widget to H3 tags?

    #1151920
    David
    Staff
    Customer Support

    Hi there,

    add this PHP snippet:

    add_filter( 'generate_start_widget_title', 'tu_adjust_widget_title' );
    function tu_adjust_widget_title() {
          return '<h3 class="widget-title">';
    }
    
    add_filter( 'generate_end_widget_title', 'tu_adjust_widget_title_end' );
    function tu_adjust_widget_title_end() {
          return '</h3>';
    }

    https://docs.generatepress.com/article/adding-php/

    #1151956
    phan cong tai

    good. thank David so much!

    #1151963
    David
    Staff
    Customer Support

    You’re welcome

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.