WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Comments title won't localize on my custom theme (3 posts)

  1. Iva
    Member
    Posted 1 year ago #

    I have copied the title from twentyleven, replaced the text domain with my own and nothing is happening. The .po generator does not recognise this and therefore I cannot translate it.

    <?php
    				printf( _n( 'One thought on &ldquo;%2$s&rdquo;', '%1$s thoughts on &ldquo;%2$s&rdquo;', get_comments_number(), 'gpk2' ),
    					number_format_i18n( get_comments_number() ), '<span>' . get_the_title() . '</span>' );
    			?>

    I'm wondering if I'm missing something fairly obvious. Thank you.

  2. I don't think printf() gets picked up by POEdit. I think it only picks up strings with __() or _e().

    However, you might be able to add it to the list?

  3. Iva
    Member
    Posted 1 year ago #

    Thank you! :) I have searched for a bit and found this:

    http://wp.tutsplus.com/tutorials/theme-development/translating-your-theme/

    However, their explanation of paths is pretty vague - it did not work until I entered the regular C:\Users\MY NAME\Desktop\gpk2\lang\

Topic Closed

This topic has been closed to new replies.

About this Topic