Add 'comment_reply_link_args' filter for get_comment_reply_link() arguments.

props joedolson, aaroncampbell, DrewAPicture.
fixes #10569.
Built from https://develop.svn.wordpress.org/trunk@30039


git-svn-id: http://core.svn.wordpress.org/trunk@30039 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Sergey Biryukov 2014-10-27 11:45:18 +00:00
parent ed4a827365
commit 0c2c7ad204
2 changed files with 13 additions and 1 deletions

View File

@ -1339,6 +1339,18 @@ function get_comment_reply_link( $args = array(), $comment = null, $post = null
return false; return false;
} }
/**
* Filter the comment reply link arguments.
*
* @since 4.1.0
*
* @param array $args Comment reply link arguments. See {@see get_comment_reply_link()}
* for more information on accepted arguments.
* @param object $comment The object of the comment being replied to.
* @param WP_Post $post The WP_Post object.
*/
$args = apply_filters( 'comment_reply_link_args', $args, $comment, $post );
if ( get_option( 'comment_registration' ) && ! is_user_logged_in() ) { if ( get_option( 'comment_registration' ) && ! is_user_logged_in() ) {
$link = sprintf( '<a rel="nofollow" class="comment-reply-login" href="%s">%s</a>', $link = sprintf( '<a rel="nofollow" class="comment-reply-login" href="%s">%s</a>',
esc_url( wp_login_url( get_permalink() ) ), esc_url( wp_login_url( get_permalink() ) ),

View File

@ -4,7 +4,7 @@
* *
* @global string $wp_version * @global string $wp_version
*/ */
$wp_version = '4.1-alpha-30038'; $wp_version = '4.1-alpha-30039';
/** /**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema. * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.