• Hi there,

    I’m not using your theme, I just had a look at the translation after a Swedish user had a question about a translation.
    There I noted that you, at least in the “by-line” glue together a bunch of very short strings, which is hard to translate (due to lack of context) and may make it hard to localize in a natural way (what if some languages would prefer to serve the pieces in a different order?).

    Let’s look at the short section I marked in the URL field:

    <div class="entry-meta">
                <?php printf( '<span class="entry-author">%s ', __( 'Written by', 'foodica' ) ); the_author_posts_link(); print('</span>'); ?>
                <span class="entry-date"><?php _e( 'on', 'foodica' ); ?> <?php printf( '<time class="entry-date" datetime="%1$s">%2$s</time> ', esc_attr( get_the_date( 'c' ) ), esc_html( get_the_date() ) ); ?></span>
                <span class="entry-category"><?php _e( 'in', 'foodica' ); ?> <?php the_category( ', ' ); ?></span>
                <?php edit_post_link( __( 'Edit', 'foodica' ), '<span class="edit-link">', '</span>' ); ?>
    </div>

    Here you create a bunch of short strings with no context for the translator (“on”, “in”)
    It would be so much better if you use printf() to give a string like:
    “Written by %1$s on %2$s in %3$s”
    … and even better if you on the preceeding line added a comment like
    // translators: 1. Author name with link, 2. Date, 3. Category

    Best regards,
    Tobi

    The page I need help with: [log in to see the link]

  • The topic ‘Please make it easier to translate your theme’ is closed to new replies.