comments_link_feed()

In this article

Outputs the link to the comments for the current post in an XML safe way.

Source

function comments_link_feed() {
	/**
	 * Filters the comments permalink for the current post.
	 *
	 * @since 3.6.0
	 *
	 * @param string $comment_permalink The current comment permalink with
	 *                                  '#comments' appended.
	 */
	echo esc_url( apply_filters( 'comments_link_feed', get_comments_link() ) );
}

Hooks

apply_filters( ‘comments_link_feed’, string $comment_permalink )

Filters the comments permalink for the current post.

Changelog

VersionDescription
3.0.0Introduced.

User Contributed Notes

You must log in before being able to contribute a note or feedback.