Title: Hi, I found this strange strings: %1$s%2&#8230;
Author: pavelevap
Published: December 12, 2010

---

 [  ](https://profiles.wordpress.org/pavelevap/) [pavelevap](https://profiles.wordpress.org/pavelevap/)
6:13 pm _on_ December 12, 2010      

# Hi, I found this strange strings: %1$s%2…

Hi, I found this strange stringsString A string is a translatable part of the software.
A translation consists of a multitude of localized strings.: %1$s%2$s|akismet_rightnow
and %1$s %2$s|akismet_rightnow.
 It should be as it is or is there any need to translate
it somehow? Also |akismet_rightnow should be as it is?

### Share this:

 * [  Threads ](https://make.wordpress.org/polyglots/2010/12/12/hi-i-found-this-strange-strings-1s2/?share=threads)
 * [  Bluesky ](https://make.wordpress.org/polyglots/2010/12/12/hi-i-found-this-strange-strings-1s2/?share=bluesky)
 * [  Facebook ](https://make.wordpress.org/polyglots/2010/12/12/hi-i-found-this-strange-strings-1s2/?share=facebook)
 * [  X ](https://make.wordpress.org/polyglots/2010/12/12/hi-i-found-this-strange-strings-1s2/?share=x)
 * [  Mastodon ](https://make.wordpress.org/polyglots/2010/12/12/hi-i-found-this-strange-strings-1s2/?share=mastodon)
 * [  WhatsApp ](https://make.wordpress.org/polyglots/2010/12/12/hi-i-found-this-strange-strings-1s2/?share=jetpack-whatsapp)
 * [  LinkedIn ](https://make.wordpress.org/polyglots/2010/12/12/hi-i-found-this-strange-strings-1s2/?share=linkedin)

 * [Login to Reply](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fmake.wordpress.org%2Fpolyglots%2F2010%2F12%2F12%2Fhi-i-found-this-strange-strings-1s2%2F%23respond&locale=en_US)

 * [To-do](https://make.wordpress.org/polyglots/2010/12/12/hi-i-found-this-strange-strings-1s2/?output_format=md#)

 1.  ![](https://secure.gravatar.com/avatar/34368b9c92a4bfa3bd2a84a222147375526d5ccfbbb3afe32abfbd1bc37f5b58?
     s=32&d=mm&r=g)
 2.   [Peter Westwood](http://westi.wordpress.com/)  6:19 pm _on_ December 12, 2010
 3.  That comes from this piece of code:
 4.   // _c was deprecated in WP 2.9.0
      if ( function_exists( ‘_x’ ) ) $text = sprintf(
     _x( ‘%1$s%2$s’, ‘akismet_rightnow’ ), $intro, $queue_text ); else $text = sprintf(
     _c( ‘%1$s%2$s|akismet_rightnow’ ), $intro, $queue_text );
 5.  You should translate the text before the “|” and leave the text after it – it 
     is the old way of providing context to a translatable stringString A string is
     a translatable part of the software. A translation consists of a multitude of 
     localized strings. before we started using the native gettext context.
 6.  ![](https://secure.gravatar.com/avatar/ea098712583c160c0f16a813f0455179f08d61e222303221f13bcb7eea9a15ee?
     s=32&d=mm&r=g)
 7.   [Milan Dinić](http://milandinic.com/)  6:43 pm _on_ December 12, 2010
 8.  To better understand what this mean, here is a complete snippet from source code:
 9.      ```notranslate
         	if ( $count = get_option('akismet_spam_count') ) {
         		$intro = sprintf( $plural_func(
         			'&lt;a href=&quot;%1$s&quot;>Akismet&lt;/a> has protected your site from %2$s spam comment already,',
         			'&lt;a href=&quot;%1$s&quot;>Akismet&lt;/a> has protected your site from %2$s spam comments already,',
         			$count
         		), 'http://akismet.com/', number_format_i18n( $count ) );
         	} else {
         		$intro = sprintf( __('&lt;a href=&quot;%1$s&quot;>Akismet&lt;/a> blocks spam from getting to your blog,'), 'http://akismet.com/' );
         	}
     
         	if ( $queue_count = akismet_spam_count() ) {
         		$queue_text = sprintf( $plural_func(
         			'and there's &lt;a href=&quot;%2$s&quot;>%1$s comment&lt;/a> in your spam queue right now.',
         			'and there are &lt;a href=&quot;%2$s&quot;>%1$s comments&lt;/a> in your spam queue right now.',
         			$queue_count
         		), number_format_i18n( $queue_count ), $esc_url($link) );
         	} else {
         		$queue_text = sprintf( __( &quot; but there's nothing in your &lt;a href='%1$s'>spam queue&lt;/a> at the moment.&quot; ), $esc_url($link) );
         	}
     
         	// _c was deprecated in WP 2.9.0
         	if ( function_exists( '_x' ) )
         		$text = sprintf( _x( '%1$s%2$s', 'akismet_rightnow' ), $intro, $queue_text );
         	else 
         		$text = sprintf( _c( '%1$s%2$s|akismet_rightnow' ), $intro, $queue_text );
     
         	echo &quot;&lt;p class='akismet-right-now'>$text&lt;/p>n&quot;;
         ```
     
 10. In short, this is a very bad part for translation and I already planned to submit
     patch that would split this to two sentences since there are already stringsString
     A string is a translatable part of the software. A translation consists of a multitude
     of localized strings. outside gettext functions which needs to be fixed before
     3.1.
 11.  * ![](https://secure.gravatar.com/avatar/e9c160c54509c9693d8981cd8d36aeefc6c9c95cbd9885822108a2992b7fac9d?
        s=32&d=mm&r=g)
      *  pavelevap  7:22 pm _on_ December 12, 2010
      * Thank you, I also was not sure what variables %1$s and %2$s really represents?
        $intro and $queue_text? But these stringsString A string is a translatable 
        part of the software. A translation consists of a multitude of localized strings.
        are translated separately?
         - ![](https://secure.gravatar.com/avatar/ea098712583c160c0f16a813f0455179f08d61e222303221f13bcb7eea9a15ee?
           s=32&d=mm&r=g)
         -  [Milan Dinić](http://milandinic.com/)  7:45 pm _on_ December 12, 2010
         - Yes, but take care about space between two.
            * ![](https://secure.gravatar.com/avatar/e9c160c54509c9693d8981cd8d36aeefc6c9c95cbd9885822108a2992b7fac9d?
              s=32&d=mm&r=g)
            *  pavelevap  7:53 pm _on_ December 12, 2010
            * Yes, but there are two stringsString A string is a translatable part 
              of the software. A translation consists of a multitude of localized strings.,
              one with spaces and second without spaces. Why? So, probably there is
              no need to “translate” these strings and I can let them as they are?
               - ![](https://secure.gravatar.com/avatar/ea098712583c160c0f16a813f0455179f08d61e222303221f13bcb7eea9a15ee?
                 s=32&d=mm&r=g)
               -  [Milan Dinić](http://milandinic.com/)  8:04 pm _on_ December 12, 
                 2010
               - It was more logical before for European languages but [this ticket](https://plugins.trac.wordpress.org/ticket/1212)
                 changed that.
               - This definitely needs to be changed since it doesn’t make any sense
                 in (probably) any language other than English.
      * ![](https://secure.gravatar.com/avatar/ea098712583c160c0f16a813f0455179f08d61e222303221f13bcb7eea9a15ee?
        s=32&d=mm&r=g)
      *  [Milan Dinić](http://milandinic.com/)  8:44 pm _on_ December 13, 2010
      * OK, [here](https://plugins.trac.wordpress.org/ticket/1248) is the ticket with
        all i18nInternationalization Internationalization (sometimes shortened to **
        I18N** , meaning “I - eighteen letters -N”) is the process of planning and 
        implementing products and services so that they can easily be adapted to specific
        local languages and cultures, a process called localization. This is the process
        of making software translatable. Information about Internationalization for
        developers can be found in the [Developer’s handbooks](https://developer.wordpress.org/).
        issues I found in Akismet. If you find any more, write it here.
         - ![](https://secure.gravatar.com/avatar/3bf6b820a2a3ece97de9c93a92eb8ead9149a5ef9a6c46ee70f39fdce815b984?
           s=32&d=mm&r=g)
         -  [Alex](http://flightpathblog.com/)  6:49 am _on_ December 15, 2010
         - There’s a followup patch to your ticket, can you confirm if it fixes the
           problems please?
            * ![](https://secure.gravatar.com/avatar/ea098712583c160c0f16a813f0455179f08d61e222303221f13bcb7eea9a15ee?
              s=32&d=mm&r=g)
            *  [Milan Dinić](http://milandinic.com/)  10:07 pm _on_ December 15, 2010
            * I posted a reply over there. Email notification on TracTrac Trac is the
              place where contributors create issues for bugs or feature requests much
              like GitHub.[https://core.trac.wordpress.org/](https://core.trac.wordpress.org/).
              doesn’t work so I didn’t see reply before.
               - ![](https://secure.gravatar.com/avatar/b08b3ac375d3b073a7de49cab22f621e759f0aadf4a5157a5ec36ffb71f52a67?
                 s=32&d=mm&r=g)
               -  [Joseph Scott](http://josephscott.org/)  8:43 am _on_ December 16,
                 2010
               - I’ve committed this new patch with a couple of exceptions.
                  * ![](https://secure.gravatar.com/avatar/ea098712583c160c0f16a813f0455179f08d61e222303221f13bcb7eea9a15ee?
                    s=32&d=mm&r=g)
                  *  [Milan Dinić](http://milandinic.com/)  10:56 am _on_ December 
                    16, 2010
                  * Thank you for your fast responses. As far as I can see, your exceptions
                    were widgets titles. Can I know why?
                  * Also, since now WP’s trunk points to Akismet’s 2.5 tag, and since
                    you patched dev branch, will this be WP 3.1 or only in next Akismet
                    version?
                     - ![](https://secure.gravatar.com/avatar/b08b3ac375d3b073a7de49cab22f621e759f0aadf4a5157a5ec36ffb71f52a67?
                       s=32&d=mm&r=g)
                     -  [Joseph Scott](http://josephscott.org/)  5:59 pm _on_ December
                       16, 2010
                     - Where the only item in the stringString A string is a translatable
                       part of the software. A translation consists of a multitude 
                       of localized strings. was ‘Akismet’ it didn’t make sense to 
                       indicate that needed a translation, since it doesn’t.
                     - Our intention is get Aksimet 2.5.1 out soon and make that the
                       version that ships with WP3.1.
 12. ![](https://secure.gravatar.com/avatar/ea098712583c160c0f16a813f0455179f08d61e222303221f13bcb7eea9a15ee?
     s=32&d=mm&r=g)
 13.  [Milan Dinić](http://milandinic.com/)  11:20 pm _on_ December 16, 2010
 14. But [there is](https://plugins.trac.wordpress.org/browser/akismet/dev/admin.php#L383)
     stringString A string is a translatable part of the software. A translation consists
     of a multitude of localized strings. that only contains “Akismet”.
 15. Does this means that we should leave Akismet in original form and not, for example,
     transcribe it to our language (as I do to Cyrillic — Акисмет)?
 16.  * ![](https://secure.gravatar.com/avatar/ea098712583c160c0f16a813f0455179f08d61e222303221f13bcb7eea9a15ee?
        s=32&d=mm&r=g)
      *  [Milan Dinić](http://milandinic.com/)  11:21 pm _on_ December 16, 2010
      * Oops, this supposed to be reply to [Joseph’s comment](https://wppolyglots.wordpress.com/2010/12/12/hi-i-found-this-strange-strings-1s2/#comment-822).

### Leave a Reply 󠀁[Cancel reply](https://make.wordpress.org/polyglots/2010/12/12/hi-i-found-this-strange-strings-1s2/?output_format=md#respond)󠁿

You must be [logged in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fmake.wordpress.org%2Fpolyglots%2F2010%2F12%2F12%2Fhi-i-found-this-strange-strings-1s2%2F&locale=en_US)
to post a comment.

# Post navigation

[← I want to use WordPress for Android in k…](https://make.wordpress.org/polyglots/2010/12/12/i-want-to-use-wordpress-for-android-in-k/)

[Bengali localization of WordPress →](https://make.wordpress.org/polyglots/2010/12/12/bengali-localization-of-wordpress/)