Definition:
function post_comments_feed_link( $link_text = '', $post_id = '', $feed = '' ) {}
Parameters
- string $link_text: Descriptive text.
- int $post_id: Optional post ID. Default to current post.
- string $feed: Optional. Feed format.
Return values
returns:Link to the comment feed for the current post.
Defined filters
- post_comments_feed_link_html
apply_filters( 'post_comments_feed_link_html', "<a href='$url'>$link_text</a>", $post_id, $feed )
Source code
function post_comments_feed_link( $link_text = '', $post_id = '', $feed = '' ) {
$url = get_post_comments_feed_link($post_id, $feed);
if ( empty($link_text) )
$link_text = __('Comments Feed');
echo apply_filters( 'post_comments_feed_link_html', "<a href='$url'>$link_text</a>", $post_id, $feed );
}
2557

February 12, 2011 


post_comment_meta_box
Definition:
function post_comment_meta_box($post) {}
Parameters
Source code
function post_comment_meta_box($post) { global $wpdb, $post_ID; $total = $wpdb->get_var($wpdb->prepare("SELECT count(1) FROM $wpdb->comments WHERE comment_post_ID = '%d' AND ( comment_approved = '0' OR comment_approved = '1')", $post_ID)); if ( 1 > $total ) { echo '<p>' . __('No comments yet.') . '</p>'; return; } wp_nonce_field( 'get-comments', 'add_comment_nonce', false ); $wp_list_table = _get_list_table('WP_Post_Comments_List_Table'); $wp_list_table->display( true ); ?> <p class="hide-if-no-js"><a href="#commentstatusdiv" id="show-comments" onclick="commentsBox.get(<?php echo $total; ?>);return false;"><?php _e('Show comments'); ?></a> <img class="waiting" style="display:none;" src="<?php echo esc_url( admin_url( 'images/wpspin_light.gif' ) ); ?>" alt="" /></p> <?php $hidden = get_hidden_meta_boxes('post'); if ( ! in_array('commentsdiv', $hidden) ) { ?> <script type="text/javascript">jQuery(document).ready(function(){commentsBox.get(<?php echo $total; ?>, 10);});</script> <?php } wp_comment_trashnotice(); }2559