comments_template

comments_template

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: filter
See hook in action

See hook in core

Displaying hooks found in version: wordpress-6.7.2

apply_filters('comments_template') is found 1 times:

  • /wp-includes/comment-template.php line 1626
    1622
    1623
    1624
    1625
    1626
    1627
    1628
    1629
    1630
    1631
    1632
    * @since 1.5.1
     *
     * @param string $theme_template The path to the theme template file.
     */
    $include = apply_filters( 'comments_template', $theme_template );
     
    if ( file_exists( $include ) ) {
        require $include;
    } elseif ( file_exists( trailingslashit( $wp_template_path ) . $file ) ) {
        require trailingslashit( $wp_template_path ) . $file;
    } else { // Backward compat code will be removed in a future release.

See this hook used in plugins: