- This topic has 8 replies, 2 voices, and was last updated 9 years, 8 months ago by Tom.
-
AuthorPosts
-
May 7, 2015 at 10:31 pm #106489Liana Ghazarian
Hi Tom,
I would like to change the language for “you searched for” to Armenian. I already have created a plugin and with your code changed the language of the word “search”. Can you help me, please?
May 7, 2015 at 11:39 pm #106507TomLead DeveloperLead DeveloperHi Liana,
Do you mean the “Search Results for:” text?
This text is translatable – all you have to do is download Poedit: http://poedit.net/
Then open the generatepress.pot file found in the “languages” folder inside Poedit.
You’ll find the above text which you can then translate to Armenian.
Then save the translation as ar.po, and upload it to your languages folder.
You can then send me the translation to support@generatepress.com, and I’ll make sure it’s in the next version by default ๐
Let me know if you need more info!
May 10, 2015 at 3:00 am #106959Liana GhazarianHi, great I can change now. I have a question though. When the text is
Search Results for: %s
The translation should be
XXX:%s
or just XXX
May 10, 2015 at 4:07 am #106968Liana GhazarianHi, Tom, I did as you said, there are no ar.po and ar.mo in the languages. But the arm language doesn’t show yet. How should i activate it?
May 10, 2015 at 8:18 am #106999TomLead DeveloperLead DeveloperYou should match is exactly, so:
Search Results for: %s
Would become:
xxx: %s
If you’ve added the language files to the languages folder in generatepress, then your changes should apply if you have your language set in “Settings > General” at the bottom.
Also, I’ve submitted 1.2.9.6 to WP.org, when they approve it and push out the update, it will remove your language files from the generatepress/languages folder. Be sure to back up your files before you update, and re-add them once the update is completed.
May 10, 2015 at 11:38 am #107036Liana GhazarianHi, Tom, my language is not supported by wordpress (it doesn’t figure among possible languages in settings/general). Does it mean I cannot change the text using this method?
May 10, 2015 at 10:47 pm #107078TomLead DeveloperLead DeveloperTry adding this into your wp-config.php file:
define ('WPLANG', 'hy_AM');
May 11, 2015 at 6:00 am #107125Liana GhazarianGreat.
I pasted the code above in wp config (which brought my site down, then some googling which taught me that the last line shouldn’t be an empty line in wp confing, so erased it and the site was working again). Then I renamed the files to hy_AM. and hy_AM.mo, put then in languages folder, chose hy_AR from the dashboard and that is it.
May 11, 2015 at 8:24 am #107184TomLead DeveloperLead DeveloperGreat!
When you update GeneratePress, you will need to re-add your language files to the languages folder.
To prevent having to do this, you can:
a) Send me the files to include in GeneratePress by default – 1.2.9.6 has already been uploaded, so you would have to re-add them once, but they would be added by default in 1.2.9.7.
b) Add your language files to your child theme: https://codex.wordpress.org/Function_Reference/load_child_theme_textdomain#Example
Let me know if you need more info ๐
-
AuthorPosts
- You must be logged in to reply to this topic.