Search Results for 'translation'
-
AuthorSearch Results
-
October 4, 2014 at 9:26 am #203962danbpParticipant
Changing words with the translation file is best practice, so you haven’t to modify anything in a core file.
If you want to modify template files, you do that with a child-theme and by respecting the same directory structure as in bp-legacy/buddypress/…/file_name.php:
wp-content/themes/your_child_theme/buddypress/…/file_name.php
1000 times explained and detailed on this forum and documented on Codex.
October 4, 2014 at 9:02 am #203957In reply to: [Resolved] buddypress.pot is OK?
danbpParticipantI’m not familiar with japanese, sorry. But it could be possible that .ja uses
1) another plural form (the one in the example is for fr and some other occidental languages)
2) another charset as utf8Read on WordPress Codex where you find more information arond these settings.
Additionaly you can also get in contact with the japanese WP translation team, for better guidance for this very specifif problem or ask for that on the WPpolyglot blog.
October 3, 2014 at 12:47 pm #203663danbpParticipantbp-languages folder is removed since 2.1
Translations are from now on automatically uploaded from GlotPress, like the WP translation.Aside this improvement, they are some little bugs, but nothing crucial, which will probably sbe olved in 2.1.1
October 3, 2014 at 7:58 am #203644In reply to: [Resolved] buddypress.pot is OK?
danbpParticipantI translated buddypress.pot from English to Japanese.(about 80%)
Guess you translated the wrong file.
Must be buddypress.po, not buddypress.pot. And you have to compile the po file into mo.In the header information, they’re missing keywords. You have only
“X-Poedit-KeywordsList: _;_;_e\n”Should be
“X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;”
“_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;_ex:1,2c;”
“esc_attr__;esc_attr_e;esc_attr_x:1,2c;esc_html__;esc_html_e;esc_html_x:1,2c\n”- Rename the file to buddypress-ja.po
- Add the above keywordlist manually, with a text editor.
- Open the file with poEdit and run “update” from source or from a blank pot file (yours contain a translation, you’ll have to get a new virgin copy)
- Translate !
September 29, 2014 at 12:59 pm #202512danbpParticipantyou jumped into an over 18 mounths old thread titled How To Limit/Hide The “Friends” Tab and you speak about translation….
Please open a new topic and give details about your issue, BP version and theme.September 29, 2014 at 11:35 am #202511full moonParticipantHello,
Is this still a viable script? I have tried it, but I get no effect.
Pobpob.com
I have changed the friends to connections in translation, but I guess that isn’t going to effect the core elements here.
Many Thanks
Leigh
September 26, 2014 at 1:21 pm #201144In reply to: [Resolved] Translation for Spanish
danbpParticipantYes it is weird ! And it is not a buddypress issue but a translation issue.
The glotpress po file is uncomplete and contains many errors.
Not sure if it can have an influence on the automatted language upload, but the header is missing the language parameter. (@r-a-y, @boone)I first tested it “as is” and got same errors as you.
I applied patch #5887… nothing
I used the function mentionned by @r-a-y… nothing
I added the mo into suggested /wp-content/languages/plugins/buddypress/bp-languages/buddypress-es_ES.mo… nothingSo i went back to my original config and used the same settings i usually use for my fr_FR BP version (/wp-content/languages/plugins/buddypress-es_ES.mo)… nothing !
WTF ? 👿 #grumbl…@?/;rrrrr !
So i decided to make a new po by updating the one found on glotpress. (i’m working with poEdit)
This resulted in around 1300 (a little more) new lines and over 100 deprecated lines… and a lot of approximative strings….In these approx, i found groups, activity and all other strings you mentionned not getting translated. I simply reverted them to valid and bam, the translation worked.
I suggest the following:
- revert back to standard config (no language patch, no language custom functions, no extra language folder) and po/mo in wp-content/languages/buddypress-xx_XX.mo
- download the po from glotpress
- open the file with a text editor and remove the header and replace it with this one:
msgid "" msgstr "" "Project-Id-Version: BuddyPress 2.1\n" "POT-Creation-Date: 2014-09-26 13:34+0100\n" "PO-Revision-Date: 2014-09-26 14:19+0100\n" "Last-Translator: \n" "Language-Team: \n" "Language: es_ES\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=n != 1;\n" "X-Poedit-SourceCharset: UTF-8\n" "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;" "_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;_ex:1,2c;" "esc_attr__;esc_attr_e;esc_attr_x:1,2c;esc_html__;esc_html_e;esc_html_x:1,2c\n" "X-Textdomain-Support: yes\n" "X-Poedit-Basepath: .\n" "X-Generator: Poedit 1.5.7\n" "X-Poedit-SearchPath-0: ..\n"
- create a folder in BP called bp-languages-ES (or whatever)
- add the po to this folder
- open the file with poEdit
- update the catalog from source
Now you can see all untranslated lines, the one who are approximative and the one who are already translated.
At this stage, the file is translated to 53% and you’ll have to translate around 770 strings (of 2668).
You also have to check each string containing count variables like %s or %1$s (many are old and must be modified). You’ll find also some plural strings. This is particulary true for approximative strings, who may be similar to the english phrase, but aren’t. Needs good eyes and slow checking ! 😉
Once finished, save your work and copy the mo file into the appropriate language folder:
/wp-content/languages/plugins/buddypress-es_ES.mo (if you want to use your custom translation only)
/wp-content/languages/buddypress-es_ES.mo – if you want automagical 👿 glotpress updates (when avaible, complete and without errors of course).September 25, 2014 at 5:17 pm #201090In reply to: [Resolved] Translation for Spanish
mabellanedaParticipantHello,
I’m suffering a lot of issues too with the translation into Spanish, in such a way that I had to patch it several times after trying different configurations.
So! To the point. It works for me now and I explain here my current configuration:
1. I’ve downloaded the BuddyPress translation package from https://translate.wordpress.org/projects/buddypress/ and contributed with some translations (specifically for Spanish: https://translate.wordpress.org/projects/buddypress/dev/es/default)
2. Saved the .mo and .po files in /wp-content/languages/plugins as recommended by the Moderators: https://translate.wordpress.org/projects/buddypress/dev/es/default.
And configured the site in Spanish (particularly I tried to do it dinamically)3. Becuase I try to change the language dinamically according to the browser preferred language I use the xili-language plugin, which “helps” you to manage in what language you’ll display your WordPress, but I’m no sure if it is decisive for the BuddyPress translation. In this plugin there’s a configuration to mention and not enough documented. In case you use the plugn, in the tub “Settings for expert” there are rules to specify. My configuration is:
Wordress rule –> translation in local
BuddyPress rule –> no modification5. At this point the translation didn’t work correctly or I didn’t succeed in translating some strings that remained in English (like: “Members”, “Groups”, “Notifications”, “Activity” in the BuddyPress navigation menu and others). So, I edited the .po file with PoEdit and updated it with the BuddyPress catalog “buddypress.pot”:
6. I updoaded the modified .po and .mo files to the mentioned folder /wp-content/languages/plugins and didn’t change a thing. I read then in forums the different issues with translations, for example:
https://buddypress.org/support/topic/translation-fails-only-at-sitewide-activity/
https://buddypress.trac.wordpress.org/ticket/5655
https://buddypress.org/support/topic/buddypress-2-1-bp-language/
https://buddypress.trac.wordpress.org/ticket/5887
https://buddypress.org/support/topic/buddypress-2-1-known-issues/ (here there’s another workaround)7. And I added the following lines to the file functions.php of my child theme:
function igf_my_child_theme_setup() {
load_child_theme_textdomain( ‘my_child_theme’, get_stylesheet_directory() . ‘/languages’ );
load_plugin_textdomain(‘buddypress’, false, basename( dirname( __FILE__ ) ) . ‘/languages/’ );
}
add_action( ‘after_setup_theme’, ‘igf_my_child_theme_setup’ );And it begans to translate correctly! I’m sorry I really don’t understand why. Furthermore I thought that the buddypress textdomain was set by the plugin xili-language but, as I said, I’m not clever enough or it is not well documented.
I know there’s a lot of steps to do, I was really frustated with it, but if you try something like this
Anyway, as this is my first post, I have to thank to the developers for the software and the great effort, of course; it has helped me a lot too.
Regards.
September 25, 2014 at 4:11 pm #201085In reply to: [Resolved] Translation for Spanish
r-a-yKeymaster@ivanguinea – If you recently added some new strings on translate.wordpress.org, you might need to force a translation update to see the changes.
By default, translation updates get updated when WordPress checks for new versions of plugins.
One way to force this is by installing the WP Crontrol plugin and by forcing the
'wp_update_plugins'
cronjob to run. Untested, but please do try and let us know if it works.September 24, 2014 at 7:20 pm #201019r-a-yKeymasterBut even if the file still loads, will it work if the line numbers are off?
It should, but for new strings introduced in BP 2.1, you’ll need to merge your translation file with the .pot file from BP 2.1 –
/wp-content/plugins/buddypress/buddypress.pot
.View the “Updating your custom language file” for how it’s done with poEdit:
We don’t have a tutorial for those using command-line tools though 🙂
September 24, 2014 at 7:09 pm #201016jreeveParticipantThanks for that, @r-a-y. I added that function to my theme so that our custom .mo file will still load when we upgrade to 2.1. But even if the file still loads, will it work if the line numbers are off? That’s to say, if the line numbers in our .mo file still correspond to a previous version of BP, will they still work in the current version of BP? If not, is there a way I can programmatically map all the older translations to the new translations file, without having to rewrite it?
September 24, 2014 at 5:06 pm #201004In reply to: [Resolved] Translation for Spanish
r-a-yKeymasterivanguinea – If you look at the Spanish translation on translate.wordpress.org, there are still some strings that haven’t been translated:
https://translate.wordpress.org/projects/buddypress/dev/es/default?filters[status]=untranslated
You can help by translating these strings. If you decide to help and are not sure how to add your contributions, let us know and we’ll point you in the right direction.
September 20, 2014 at 10:00 pm #198735Shawn74ParticipantUPDATE: This issue is caused by my Italian translation…. now i’m searching the string, thanks you anyway
September 19, 2014 at 5:29 pm #197974In reply to: Buddypress Activity Link (time ago) Issue
CartographerParticipantHi @danp
If I write the title in English there is no problem. The problem occurs only with greek characters.
I removed the greek translation of WB an BP but still no luck.
The strange part (as I see it) it is that the issue occurs only for the freshness column of the Sitewide Activity post. Everywhere else the link is ok.
I hope a solution will be found.
Thank you
September 19, 2014 at 4:00 pm #197965In reply to: Buddypress Activity Link (time ago) Issue
danbpParticipantremove the greek translation of WP and BP and test in english
September 12, 2014 at 11:30 am #192185In reply to: [Resolved] Translation Not Working
danbpParticipantGlad you got it to work !
FYI: BP Poke comes with his own languages folder who contains po/mo in english. This is wrong, but has no influence if you want to use another language.
The reason is that many authors create a po file instead of a pot file, and when they save the file, poEdit (or similar) automatically creates a mo file.
The correct file name should be bp-poke.pot ! You can remove the original – in english – mo, totally useless: the plugin is coded in english !To use a translation for this plugin, you add xx_XX.mo to bp-poke/languages/xx_XX.mo
Text domain ref: bp-poke.php:50
September 12, 2014 at 10:21 am #192182In reply to: [Resolved] Translation Not Working
geistschattenParticipantThank you! That worked perfect and now I see my translated terms. I tried the same process for BP Poke and it didn’t seem to work (even renamed the translation files to bp-poke-en_US.mo/po and dropped them in the languages/plugins folder). Oh well though, not as important as the main change. I’m a happy camper, so to speak… 🙂
September 11, 2014 at 10:44 pm #192079In reply to: [Resolved] Translation Not Working
danbpParticipantI just tested Duena and the BP translation is fine.
Recheck your po/mo files. Here what you must have:
duena – leave as is.
buddypress/bp-languages/buddypress.pot
wp-config – if you use english, as it’s default language you have nothing to do
// define(‘WP_LANG’, ” );
wp-content/languages/plugins/buddypress-en_US.moNow if you want to modify only some strings, make a copy of the pot file and put it in a folder outside of buddypress.
From this copy you remove anything you don’t want and keep only the 2 lines or 4 lines (if plural form) who belong to the string you want to change. You keep only the string you want to change.
Once done, save and rename it buddypress-en_US.po and open it with a text editor (not poEdit), as we’re going to modify the header.msgid "" msgstr "" "PO-Revision-Date: 2014-09-12 00:05+0100\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=n > 1;\n" "X-Generator: Poedit 1.5.7\n" "Project-Id-Version: BuddyPress 2.0.2\n" "POT-Creation-Date: \n" "Last-Translator: \n" "Language-Team: \n" "Language: en\n" "X-Poedit-SourceCharset: UTF-8\n" "X-Poedit-Basepath: .\n" "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;" "_n_noop:1,2;_x:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;_ex:1,2c;esc_attr__;" "esc_attr_e;esc_attr_x:1,2c;esc_html__;esc_html_e;esc_html_x:1,2c\n" "X-Poedit-SearchPath-0: ..\n"
The rest of the file looks like this:
msgid "Friendships" msgstr "" <strong><- replacement goes here</strong> #: bp-friends/bp-friends-template.php:588 msgid "%s friend" msgid_plural "%s friends" msgstr[0] "" msgstr[1] ""
Save in text format utf8 without BOM. (important)
Now you can open this po file with poEdit, do your translation and save so that poEdit generate a mo file (see poEdit settings first to get this automatically each time you save a file).
Copy the mo file in the appropriate folder and, normally, you’re done.
References
https://codex.wordpress.org/Translating_WordPress
https://make.wordpress.org/polyglots/handbook/translating/basics/
http://www.wpbeginner.com/wp-tutorials/how-to-disable-automatic-updates-in-wordpress/The definitive guide to disabling auto updates in WordPress 3.7
September 11, 2014 at 8:00 pm #192075In reply to: [Resolved] Translation Not Working
geistschattenParticipantI called it a tutorial, I just meant this page: https://codex.buddypress.org/getting-started/customizing/customizing-labels-messages-and-urls/
I’ve removed the bp-custom.php file entirely.
Thank you for the list of where to put the translation files and the tip about poEdit! I installed poEdit, opened my edited .pot file, exported the .po and .mo files, uploaded them to the appropriate directories and changed to the language in wp-config to “en_US” while naming the files buddypress-en_US.po and buddypress-en_US.mo
Still no translations showing up (even after several refreshes and Ctrl+F5), but I did discover a couple errors with my file while editing it. Something about duplicate definitions, which I fixed.
Again, all I’m trying to do is change friends, friendships, friend requests, etc. to something else. A simple translation for only BuddyPress seemed to be the easiest way to do that.
September 11, 2014 at 12:52 pm #191897In reply to: [Resolved] Translation Not Working
danbpParticipant11. Do you have any custom functions in bp-custom.php? Yes, the function from every tutorial talking about the language, but changed for my custom language file.
Which tutorial are you telling about ?
Remove that function, it’s not necessary i guess.
By default, you set your site language in wp-config define ( ‘WP_LANG’, ‘de_DE’ ); and in wp settings > general (depending if single or MS install)
Where to put the translation ?
wp-content/languages/de_DE.mo (this is the WP translation)
wp-content/languages/plugins/buddypress-de_DE.mo (this is the BP translation)
wp-content/languages/themes/theme_name-de_DE.mo (this is the theme translation)You say you used gedit to generate your translation. It’s a text-editor, not a mo compiler. (mo means machine only, you can’t read it !)
I suggest that you use poEdit to make a translation and generate a correct mo file.
On Ubuntu, you can (not sure) use the msgmt command from the gettext package. Something like this$> msgfmt -o your_file.mo -v your_file.po
September 8, 2014 at 9:42 am #190919In reply to: [Resolved] bbPress and BuddyPress translation
giggioParticipantYes, the files are in correct directory but the translation not work. Before the 4.0 update of wordpress there was not problem … Here is the site – http://pokerspirit.net/forum/new-topic/
September 8, 2014 at 9:02 am #190912In reply to: [Resolved] bbPress and BuddyPress translation
danbpParticipantverify that your translation files are in the correct directory.
For bbPress:
wp-content/languages/bbpress/bbp-xx_XX.mo (required)
wp-content/languages/bbpress/bbp-xx_XX.po (option)
where xx is your languageFor BuddyPress:
wp-content/languages/plugins/buddypress-xx_XX.mo (required)
wp-content/languages/plugins/buddypress-xx_XX.po (option)FYI: both plugins are shipped with a pot file containing the strings you can translate.
/plugin_name/languages/plugin_name.potDon’t put a translation in this folder, as it will be overwritten at each update.
September 6, 2014 at 5:58 pm #190323In reply to: Registration Form Error Message
danbpParticipantplease don’t jump into old post !
You want to modifify this phrase:
Registering for this site is easy. Just fill in the fields below, and we’ll get a new account set up for you in no time. who sit on the register page.
The string is in bp-templates/bp-legacy/buddypress/members/register.php line 22
and in the pot file of bp 2.0.2 at line 1236.The pot file is a working copy for translators, not the file to modify to get any customization.
To do this you have to use poEdit, or a similar software.
poEdit only read the pot file, then he create a po file on the fly and when you save this po file, poEdit generate a mo file.This is a compiled file, not human readable, who is used by the gettext php module to translate the strings he find in the buddypress code.
Pot files are provided by the plugin authors. It’s a simple text format file with a specific syntax.
The po file is also a text format file, but written differently, as it contains the original string in english AND the translation of this string in a foreign language.
And the mo file is the system file who have to use on the server.register.php is a template file, so if you have to change only this phrase, you can make a copy and paste it into your child-theme and modify the wording directly in the file. Not orthodox, but it works.
If you have other question about translation or wordings, feel free to open your own topic, give your bp version, theme name and used language on the installation.
Topic closed.
September 6, 2014 at 5:39 pm #190321In reply to: [Resolved] How to customize register-page
danbpParticipantyou jumped into a topic marked as resolved 14 mounth ago ! Please open a new one and indicate your theme, the language you use and where you pick up the translation.
Topic is now closed.
September 4, 2014 at 10:52 am #189599In reply to: Extended Profiles / Can't edit the fields
danbpParticipantIt is not an issue, it is intended so !
The logged user’s profile tab comes with 3 sub menus:
– View (public)
– Edit (private)
– Change avatar (private)On the main navigation of the member, you have at least
– Settings with 3 sub nav items:
– account credential (email, password)
– notifications
– field visibility settingsAnd if component is activated:
– Friends
– Groups
– ForumI agree that this Setting is confusing, at least, because those labels should indicate My Friends, My Groups, My Forums and My profile fields visibility settings, which is too long i grant you. 😉
FYI: such distinction wern’t really possible untill now in the original english version.
But the upcomming BP 2.1 brings some better context disambiguation just to improve such situation.To solve this today, you can:
1) create a translation file and modify the wording (but, as said, without disambiguation)
2) use a child theme and hardcode the text you want into the template file (best approach)
3) wait a few days for 2.1 to use the first option -
AuthorSearch Results