author expired_AUTHOR_EMAIL FILTER自定义评论作者的EMAIL

更新时间:2019-09-26    来源:网页配色    手机版     字体:

【www.bbyears.com--网页配色】

apply_filters ( ‘author_email’, string $author_email, int $comment_ID )


在wp-includes/comment-template.php的comment_author_email函数中用到了author_email的filter。

function comment_author_email( $comment_ID = 0 ) {
    $author_email = get_comment_author_email( $comment_ID );
 
    /**
     * Filter the comment author"s email for display.
     *
     * @since 1.2.0
     * @since 4.1.0 The `$comment_ID` parameter was added.
     *
     * @param string $author_email The comment author"s email address.
     * @param int    $comment_ID   The comment ID.
     */
    echo apply_filters( "author_email", $author_email, $comment_ID );
}

本文来源:http://www.bbyears.com/wangyezhizuo/69550.html