[wp-trac] [WordPress Trac] #42380: Add comment url filter to comment list table

WordPress Trac noreply at wordpress.org
Fri Dec 8 01:20:46 UTC 2017


#42380: Add comment url filter to comment list table
-------------------------------------------------+-------------------------
 Reporter:  danieltj                             |       Owner:
     Type:  enhancement                          |      Status:  new
 Priority:  normal                               |   Milestone:  Awaiting
Component:  Comments                             |  Review
 Severity:  normal                               |     Version:  4.8.2
 Keywords:  good-first-bug has-patch needs-      |  Resolution:
  testing                                        |     Focuses:
-------------------------------------------------+-------------------------

Comment (by birgire):

 Thanks for the patch @ashokrd2013

 In the ''Core Contributor Handbook'' there's a good description how to
 document filters:

 https://make.wordpress.org/core/handbook/best-practices/inline-
 documentation-standards/php/#4-hooks-actions-and-filters

 but I noticed that the function {{{get_comment_author_url()}}} contains
 the following filter:


 {{{
  /**
   * Filters the comment author's URL.
   *
   * @since 1.5.0
   * @since 4.1.0 The `$comment_ID` and `$comment` parameters were added.
   *
   * @param string     $url        The comment author's URL.
   * @param int        $comment_ID The comment ID.
   * @param WP_Comment $comment    The comment object.
   */
   return apply_filters( 'get_comment_author_url', $url, $id, $comment );

 }}}

 https://core.trac.wordpress.org/browser/tags/4.9.1/src/wp-includes
 /comment-template.php#L302

--
Ticket URL: <https://core.trac.wordpress.org/ticket/42380#comment:4>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list