[Support request] widget title + span

Home Forums Support [Support request] widget title + span

Home Forums Support widget title + span

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #976843
    Capital Link

    I would like to add <span> after the <h2 class=”widget-title”>

    How can I do this?

    I use child theme.

    #976895
    David
    Staff
    Customer Support

    Hi there,

    you can try adding this PHP snippet:

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

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

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