helpful_headline_html

Sometimes it is necessary to manipulate the HTML tag of the Helpful Heading. To make this easy, there is a filter that holds the Helpful Heading. Here you can swap the h3 with a h2.

/**
 * Replace the h3 heading with an h2 heading.
 *
 * @param string $default
 * @return string
 */
add_filter('helpful_headline_html', function (string $default) {
    return str_replace('h3', 'h2', $default);
});

Was this post helpful?

Top