Make WordPress Core

Changeset 16614


Ignore:
Timestamp:
11/29/2010 06:42:31 PM (16 years ago)
Author:
nbachiyski
Message:

Make comments_popup_link() calls in Twenty Ten respect languages with multiple plural forms until we add such support in comments_number(). See #13651, props zeo

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-content/themes/twentyten/loop.php

    r16589 r16614  
    5454         * Without further ado, the loop:
    5555         */ ?>
    56 <?php while ( have_posts() ) : the_post(); ?>
     56<?php while ( have_posts() ) : the_post();
     57
     58$comment_number_template = _n( '% Comment', '% Comments', get_comments_number(), 'twentyten' );
     59?>
    5760
    5861<?php /* How to display posts in the Gallery category. */ ?>
     
    9497                                <span class="meta-sep">|</span>
    9598                        <?php endif; ?>
    96                                 <span class="comments-link"><?php comments_popup_link( __( 'Leave a comment', 'twentyten' ), __( '1 Comment', 'twentyten' ), __( '% Comments', 'twentyten' ) ); ?></span>
     99                                <span class="comments-link"><?php comments_popup_link( __( 'Leave a comment', 'twentyten' ), $comment_number_template, $comment_number_template ); ?></span>
    97100                                <?php edit_post_link( __( 'Edit', 'twentyten' ), '<span class="meta-sep">|</span> <span class="edit-link">', '</span>' ); ?>
    98101                        </div><!-- .entry-utility -->
     
    117120                                <?php twentyten_posted_on(); ?>
    118121                                <span class="meta-sep">|</span>
    119                                 <span class="comments-link"><?php comments_popup_link( __( 'Leave a comment', 'twentyten' ), __( '1 Comment', 'twentyten' ), __( '% Comments', 'twentyten' ) ); ?></span>
     122                                <span class="comments-link"><?php comments_popup_link( __( 'Leave a comment', 'twentyten' ), $comment_number_template, $comment_number_template ); ?></span>
    120123                                <?php edit_post_link( __( 'Edit', 'twentyten' ), '<span class="meta-sep">|</span> <span class="edit-link">', '</span>' ); ?>
    121124                        </div><!-- .entry-utility -->
     
    159162                                        <span class="meta-sep">|</span>
    160163                                <?php endif; ?>
    161                                 <span class="comments-link"><?php comments_popup_link( __( 'Leave a comment', 'twentyten' ), __( '1 Comment', 'twentyten' ), __( '% Comments', 'twentyten' ) ); ?></span>
     164                                <span class="comments-link"><?php comments_popup_link( __( 'Leave a comment', 'twentyten' ), $comment_number_template, $comment_number_template ); ?></span>
    162165                                <?php edit_post_link( __( 'Edit', 'twentyten' ), '<span class="meta-sep">|</span> <span class="edit-link">', '</span>' ); ?>
    163166                        </div><!-- .entry-utility -->
Note: See TracChangeset for help on using the changeset viewer.