Switch language

wpseek.com
A WordPress-centric search engine for devs and theme authors




get_previous_comments_link [ WordPress Function ]

get_previous_comments_link ( $label = '' )
Parameters:
  • (string) $label Optional. Label for comments link text.
Returns:
  • (string|null)
Defined at:



Return the previous comments page link.

Source


<?php
function get_previous_comments_link$label '' ) {
    if ( !
is_singular() || !get_option('page_comments') )
        return;

    
$page get_query_var('cpage');

    if ( 
intval($page) <= )
        return;

    
$prevpage intval($page) - 1;

    if ( empty(
$label) )
        
$label __('&laquo; Older Comments');

    return 
'<a href="' esc_urlget_comments_pagenum_link$prevpage ) ) . '" ' apply_filters'previous_comments_link_attributes''' ) . '>' preg_replace('/&([^#])(?![a-z]{1,8};)/i''&#038;$1'$label) .'</a>';
}
?>

Examples [ wp-snippets.com ]

Top Google zoekresultaten

Meer ...

Gebruikersdiscussies [ wordpress.org ]

0 User Note(s)

Nog geen één. Wees de eerste!

Nieuw toevoegen ...



HTML5 Powered with CSS3 / Styling, Performance & Integration, and Semantics