comments_link

函数


comments_link ( $deprecated = '', $deprecated_2 = '' )
参数
  • (string)
    $deprecated
    Not Used.
    Required:
    Default: (empty)
  • (string)
    $deprecated_2
    Not Used.
    Required:
    Default: (empty)
定义位置
  • wp-includes/comment-template.php
    , line 837
引入
0.71
弃用

显示当前文章评论的链接。

function comments_link( $deprecated = '', $deprecated_2 = '' ) {
	if ( ! empty( $deprecated ) ) {
		_deprecated_argument( __FUNCTION__, '0.72' );
	}
	if ( ! empty( $deprecated_2 ) ) {
		_deprecated_argument( __FUNCTION__, '1.3.0' );
	}
	echo esc_url( get_comments_link() );
}