So in english we don’t have gendered nouns. It is always “a table” or “a desk” with no need to worry about it being “une table” or “un tableau” (french). So my question is that when working on the french .mo file, how does one translate a string such as :
You can include a %s in a childtheme
since the “a” depends on what the %s is?
This is not a problem if every string gets its own template for translation.
If you use the string
You can include a %s in a childtheme.
more than one time for different nouns it is not translatable.An example, taken from a recent article:
New %s
is in German (yes, we have gendered nouns too) â¦â¦ so you have to write
New book
andNew movie
orYou can include a logo in a child theme.
andYou can include a stylesheet in a child theme.
.Side note
Thatâs one of the reasons why translation files take so much memory: You have to ârepeatâ many very similar strings. While a WordPress installation in English will probably run fine with 32MB PHP memory it will just die if you use the same with a German or French translation.
If your theme or plugin is using many translatable strings for front-end and back-end consider using two files: one for the back-end and a separate file for the front-end.
The WordPress core just changed to this system for better performance.
Helga, you Viking… I’d say this is one dam of a simple and intriguing question..!
In a simple view, looks like the issue is the
%s
and not the gender:Complexifying the matter, I donnow if a gettext toscho’s retranslate wizardry would address this, or if it is off-topic and should be taken care of by WP Polyglots.
side note: How-to: Translate plural forms for themes/plugins with PoEdit