[wp-trac] [WordPress Trac] #34442: How to target only the get_comments() query in comment_template()
WordPress Trac
noreply at wordpress.org
Sun Jan 10 12:35:35 UTC 2016
#34442: How to target only the get_comments() query in comment_template()
-------------------------+---------------------------
Reporter: birgire | Owner: boonebgorges
Type: enhancement | Status: closed
Priority: normal | Milestone: 4.5
Component: Comments | Version: 4.3.1
Severity: normal | Resolution: fixed
Keywords: | Focuses:
-------------------------+---------------------------
Comment (by birgire):
Great ;-)
I added the patch ''34442-2.diff'' to include the inline documentation for
''include_unapproved'', since it's also part of the {{{$comment_args}}}
setup within {{{comments_template()}}}:
{{{
if ( $user_ID ) {
$comment_args['include_unapproved'] = array( $user_ID );
} elseif ( ! empty( $comment_author_email ) ) {
$comment_args['include_unapproved'] = array( $comment_author_email );
}
}}}
I used the parameter description from the inline {{{WP_Comment_Query}}}
class documentation.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/34442#comment:4>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list