Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'translation'

Viewing 25 results - 351 through 375 (of 1,142 total)
  • Author
    Search Results
  • #238046
    Prometheus Fire
    Participant

    @shanebp and @danbp thank you for the replies on this. I did my change of this using Codestyling Localization. That didn’t work (it worked everywhere but in the subnav). Then I manually created po/mo files and it also worked everywhere but in the subnav. When I did that translation, I created the po using an online po edit (I don’t remember which one, and it certainly didn’t say anything about source keywords).

    I’ve now installed a copy of PoEdit on my pc and am working through the file now, with the keyword information mentioned in the link above.

    I have a couple additional question though, because I’ve found conflicting information on the internet and following the instructions from the BP documentation doesn’t seem to work right.

    The buddypress-en_US.po and buddpress-en_US.mo files need to be in which folder?

    The documentation says to put them in /wp-content/languages/plugins/ however, sources I’ve seen elsewhere say to put them in /wp-content/languages/ – currently neither of them work for me, but I’m starting this translation from scratch now and I want to get it right.

    Also, does the language define statement in wp-config.php need to be set for this to work? Keep in mind that I’m not doing a full on translation, just this BuddyPress translation to change Friends to Connections.

    #238041
    danbp
    Participant

    @prometheus-fire,

    this is obvious, but unfortunately despite your details, difficult to help out, because you don’t tell which code is concerned… or what you used to do your change. ๐Ÿ˜‰

    Generally, when it doesn’t translate, it’s because a typo error. A custom function, a theme using outdated strings and a lot of little details like missing dots, comas or percent sign.

    Here some tricky examples which can produce a missing translation.
    Original code looks like this:

    %d friends
    
    Activity feed for %s's friends.
    
    Friends <span class=\"%s\">%s</span>

    If %d is typed %s, or if the end point after friends is missing or you forgot to anti-slash or a double cote in the html, gettext mismatch the source and the translation and doesn’t execute it.

    First thing to do in your situation, is to compare what is in your po file to what is in the BP code. Assuming BP code is the master, and always right. Po can be wrong: old version, manually modified, corrupted. Po must in any case be saved as text format in utf8 without BOM. This is invisible, but a real source of issues, specially when anything seems the same and desperatly stays untranslated/unmodified.

    To do this, open the po in a text editor. Search for the string, check the file position given above the string, and read carefully and triple check, that the original BP code and the string in the po are strictly identic.

    If nothing found, ensure there is no custom function somwhere, or a theme playing around the buddybar or subnav.

    #238039
    shanebp
    Moderator

    Are you sure you’ve translated this label: Friends <span class="%s">%s</span>

    Did you include this Sources Keyword when creating the translation .mo in poEdit: _x()

    The Friends label is generated by __() and _x(), depending on the context.

    More info re keywords: http://www.cssigniter.com/ignite/wordpress-poedit-translation-secrets/

    #237431
    mrgiblets
    Participant

    Just to add to Roger’s brilliant post above…

    Don’t be afraid of Poedit.

    It can look a bit intimidating at first but it really isn’t.

    I’ve always edited language files directly in a text editor but I decided to give Poedit a whirl.

    What caught me out was the fact that when I first opened it I was editing the actual strings and then exporting the PO & MO files.

    This wasn’t doing anything because it was the wrong way to do it.

    For every string there is a blank translation box beneath it, this is where you need to put your “translation”, then export, upload and boom, works a treat ๐Ÿ˜‰

    #237370
    Roger Coathup
    Participant

    Changing these titles isn’t the easiest thing, but BuddyPress does provide 2 ways you can do it. However, hacking core files like bp-activity-loader.php is definitely not one of them. [Never hack core files — have a Google if it’s not obvious to you why you shouldn’t]

    Ok the 2 solutions are:

    1. Use a language / translation file
    2. Use the template hierarchy

    The string “Site-Wide Activity” is translatable — all the strings are. You can implement a language file that translates ‘Site-Wide Activity’ into whatever string you’d like. Have a search for translating BuddyPress strings / POT files / poedit. There’s also a documentation (they call it the Codex) page on it: https://codex.buddypress.org/getting-started/customizing/customizing-labels-messages-and-urls/

    The second solution is to use the template hierarchy. If you don’t provide a specific template for your activity directory, BuddyPress will use the page.php file from your theme and ‘inject’ the title “Site-Wide Activity” where page.php makes a call to the_title().

    You can override this by implementing your own template — create a file called index-directory.php inside /buddypress/activity in your site’s theme. Copy the basics of page.php into that file, and replace the_title() with your hardcoded title for the page.

    You can read more about the template hierarchy here: https://codex.buddypress.org/themes/theme-compatibility-1-7/template-hierarchy/

    Neither solution is simple, you’ll either have to get your head around using poedit, or need some basic PHP coding skills and an understanding of the principles of templates and themes in WordPress. In the future, it would be nice to see a settings panel in wp-admin to configure these basic strings.

    [p.s. if you don’t want to use poedit, you could take a look at plugin solutions for string translation, e.g. codestyling localisation]

    #236922
    ChristophK2003
    Participant

    Hi.

    I am also using wordpress 4.1.1 and buddypress 2.2.1 and for all pages, which I need to map via the settings page I am getting a blank page: Groups, Members, Register and Activate. I am using the default theme. It is a multi-site setup, however buddypress is only used on the main site (first blog) and also only there activated.
    I did only minor styling via the themes css and the header.php.

    WP_Debug does not show any errors as well as the Apache log is empty.

    It was working fine until i updated recently the connected bbpress for forum.

    Besides that I am using following plugins:
    bbP private groups
    bbPress
    bbPress Advanced Capabilities
    BP Registration Options (DEACTIVATED CURRENTLY)
    BuddyPress
    BuddyPress Group Email Subscription
    BuddyPress Like (DEACTIVATED CURRENTLY)
    BuddyPress Multilingual
    HookPress (DEACTIVATED CURRENTLY)
    Nginx Helper (only on staging)
    Page Builder by SiteOrigin (DEACTIVATED CURRENTLY)
    Paid Memberships Pro
    Paid Memberships Pro – bbPress Add On
    Paid Memberships Pro – Register Helper Add On
    Social Login

    Network activated:
    WordPress SEO
    WPML Multilingual CMS
    WPML String Translation
    Events Manager

    My dev environment is XAMPP on Mac and on the staging is a linode cloud server with Ubuntu on Nginx (I think). Both have the same issues.
    It’s not a live site yet, just demo, therefore some of the plugins might get activated if I am back on track.

    Tried it now to get it run for about 15 hours:
    – I also deactivated all plugins except buddypress and still did not get any of those sites working.
    – Actiavated / Deactivated the plugins
    – Used the repair tools
    – looked into all my codes and fixed file endings such as empty space after ?> in php files
    – Reassigned all sites
    – Researched a lot in million of forums

    Any hint, idea, glimps or full stack solution is highly appreciated.

    Thanks, Chris

    #236887

    In reply to: Admin bar translation?

    danbp
    Participant

    The po file you used initially contains errors or missing strings. This file is on glotpress and indicate it is 100% translated. Problem is, that Glotpres doesn’t control the syntax and 100% translated doesn’t mean working to 100%.

    If you use this po file as work base, you have already 95% translated and probably some typo errors. poEdit handle this and shows you which strings are not “completed” or have “changed”. In this case, you have to validate the translation. Such difference are highlighted in a different color, so they’re easy to see.

    It’s not automated, but a kind of.

    Similar topics
    https://buddypress.org/support/topic/problem-with-spanish-translation/
    https://buddypress.org/support/topic/po-not-working-on-registration-page/

    #236886

    In reply to: Admin bar translation?

    GuidoFTO
    Participant

    So you are saying to get a POT file and produce a new Spanish translation from scratch as a .MO?

    what i did is… get the .POT opened it and translated all the words called “Group”… i exported as .MO and uploaded to the buddypress translation directory and the word “Group” was successfully translated to Spanish as “Grupos”.

    i guess translating all manually will solve my problem…

    but is there a way to at least get some of it filled out automatically?

    Regards

    #236882

    In reply to: Admin bar translation?

    danbp
    Participant

    Here what i have on my test install, 2012 + wp+bp in spanish

    screenshot toolbar menu

    as you see, the wp part IS in spanish, and most of the bp items are in english, and some are in spanish.

    Guess you have to review the whole translation manually with poedit or at least try to setup your site to another spanish format, so that bp could use that one. With a little chance, one of them is correctly translated.

    Open the po file with poedit and update it with the POT file shipped with BP 2.2.1.
    And complete/modify the translation, save and add the mo file to live site languages/plugins/ directory.

    #236880

    In reply to: Admin bar translation?

    GuidoFTO
    Participant

    I have changed to twenty fifteen theme and then i changed to italian and all the admin bar was pefectly fine in italian language…

    So then i changed language to Spanish (still in twenty fifteen theme) and the admin bar was in English, translation did not work at all, and now everything is in English not just the top part of the menu XD.

    Now i am back in my True Mag theme and all the Admin Bar is in English and it is not picking up the Spanish translation anymore…

    so in conclusion we went to worst now… haha

    any tips? XD

    #236875

    In reply to: Admin bar translation?

    danbp
    Participant

    I can’t help you for a premium theme as i have no access to it without paying.
    See theme’s support for that.

    But before, let’s try something other.

    Set your site language to italian and save. WP will upload the italian translation. If not, do it manually from glotpress and see that you have wp-content/languages/it_IT.mo

    Your site is now in italian. Verify the menu translation. If it’s still in english, deactivate your theme and activate 2014 or 2015. The menu should be now in italian.

    If it is the case, set site language to spanish and check the menu. Should be in spanish. If ok, reactivate your theme.

    If the menu remains in english, contact the theme support.

    #236126
    jaydd
    Participant

    I read the whole thing, nut couldnt really get to make it work:/
    Could you please explain me what exactly i should do to get translation work?
    I downloaded hu_HU po and mo files from wp translate website(i know its not fully complete, but yet those which are are not being translated), i saw you wrote to put them into wp-content/languages/plugins -done that. What further steps do i have to make?

    #236111
    danbp
    Participant

    bp-languages folder doesn’t exist in BP 2.x

    If your WP use hungarian language, when you install BP, the BuddyPress translation comes automatically from translate-wordpress.org into wp-content/languages/plugins/, which contains also by default the askimet translation.

    Also, php gettext use the compiled mo format to show a translation. The po file is only used to translate.

    Much more about translation in this topic.

    #235414
    @mercime
    Participant

    @numumar Sorry, something may be getting lost in translation. Could you please clarify what you mean?

    #235248
    danbp
    Participant

    @marketraisen,

    the original code is %s posted an update
    To modify this the right way, you have to use the language file and an appropriate compilator such as poEdit to generate the mo file.

    Don’t know what solution you didn’t found, guess you have to search this forum for translation related topics.

    A very dirty solution would be to use this snippet and add it to your child-theme functions.php

    function marketraisen_change_bp_update_text( $translated, $original_text, $domain ) {
    		
    	if ( 'buddypress' !== $domain )  
    	return $translated; 
    	
    	switch ( $original_text ) {
    		case '%s posted an update':
    		return '%s posted on';
    				
    		default:
    		return $translated;
    	}
    }
    add_filter( 'gettext', 'marketraisen_change_bp_update_text', 10, 3 );
    #234529
    r-a-y
    Keymaster

    danbp – You’re right. My technique will work, but would get overwritten when translations are automatically updated.

    I just checked and WordPress saves automatic translations to /wp-content/languages/plugins/ so we should be safe if custom BP translation files are saved to /wp-content/languages/buddypress or /wp-content/languages.

    WordPress might say that there is a new BuddyPress translation, but if you’re using the custom method, then you can ignore the notice as BuddyPress will keep using the custom translation file.

    To tell WordPress to stop fetching automatic translations for BuddyPress, see:
    https://buddypress.org/support/topic/disable-automatic-translation-updates/#post-234528

    #234499
    danbp
    Participant

    @r-a-y

    guess you’re wrong !

    Put your language file here:
    /wp-content/languages/buddypress/
    And you will not have to worry about upgrades removing your language file.

    /wp-content/languages/buddypress/ is the directory where glotpress uploads the BP translation file.

    – when the directory is empty ( a first install for example)
    – when the mo file is old
    – the file is also checked when you modify your site language

    To test, make main site to english, throw an old BP .mo into that directory
    Revert site language to fit this mo and you’re immediatly invited to update your translation.

    The place to put a custom po/mo is /wp-content/languages/
    buddypress.mo in this directory is not overwriten.

    But it’s unclear to me (for the moment) if this directory is completly overwriten when WP updates ?
    But i’m sure it was not the case in the past < BP 1.9/WP 3.9 ๐Ÿ˜‰

    #233916
    r-a-y
    Keymaster

    You have to merge your .pot file with the latest one located in /wp-content/plugins/buddypress/buddypress.pot.

    Read the “Updating your custom language file” section of this codex article:

    Customizing Labels, Messages, and URLs

    For other plugins, placing your custom translations in /wp-content/plugins or /wp-content/languages/plugins/ should work.

    #233696
    Paul Wong-Gibbs
    Keymaster

    Hi @kkradel

    Sorry to hear you’re having problems with 2.2. How has it broken Featured Posts — can you explain what you’re seeing, and also what you expect to see?

    Did you update any other plugins, translations, or core files at the same that you updated BuddyPress?

    danbp
    Participant

    I guess something is not translated, but in this case, the email text should come in english.

    If yo use an “old” translation from a previous version, it is possible that something is missing in your translation.

    After checking both portugese version on GlotPress, (pt_PT and pt_BR) it appears that pt_PT is not translated for 2.1.x and to 38% for pt_PT in the dev version – the one actualy used by BP 2.1.1

    https://translate.wordpress.org/projects/buddypress/dev

    If you use an email plugin, ensure it is matching with WP’s mail action. Or if your theme has is own mail function, check that he uses the same wording as BP (and particulary the $s var) who fires the link.

    Code in 2.1.1 looks like this

    %1$s,\n
    \n
    \n
    \n
    Thanks for registering! To complete the activation of your account and blog, please click the following link:\n
    \n
    %2$s\n
    \n
    \n
    \n
    After you activate, you can visit your blog here:\n
    \n
    %3$s
    #233176
    deshmukh
    Participant

    Look the Codex up. There is a section on using custom stubs/ translations using .po and .mo files. That should do it.

    Mathuseo
    Participant

    Ok thanks. So I probably have problems to unterstand your answer before. The state of play is:

    In .pot-file there is: Notifications <span class=\"%s\">%s</span>
    In .po-file buddypress-de_DE.po there is: Notifications <span class=\"%s\">%s</span>
    In .po-file buddypress-de_DE.po there is the translation: Benachrichtigungen <span class=\"%s\">%s</span>

    That should working I think. But it do not.

    danbp
    Participant

    The pot file doesn’t contain the translation, only the strings you can translate.

    The translation is done in po (not pot) file and compiled to a mo file. buddypress-de_DE.mo is the file you have to use.

    Mathuseo
    Participant

    @danbp: Thanks for your help. But it’s still not working. What I have done:

    (1) Downloaded newest version of buddypress (2.1.1).
    (2) Replaced my current buddypress.pot on webserver with the newest version (buddypress/buddypress.pot).
    (3) Open the file with poedit.
    (4) Looked for Notifications <span class=\"%s\">%s</span>
    (5) Added the translation Benachrichtigung <span class=\"%s\">%s</span>
    (6) Upload the buddypress.pot again.

    Is there any mistake in my way to fix that problem? I’m using a child theme if this is important to you.

    Thank you for helping me!

    danbp
    Participant

    As you can see in the BP source (2.1),
    $nav_name = sprintf( _x( 'Notifications <span class="%s">%s</span>', 'Profile screen nav', 'buddypress' ), esc_attr( $class ), number_format_i18n( $count ) );

    This string in po. is outdated: Notifications <span class=\โ€count\โ€>%s</span>

    You have to open your actual po file with poEdit (or similar translation tool) and update it with the pot file comming with latest BP version. (/buddypress/buddypress.pot)

    Once updated the string to translate will be:
    Notifications <span class=\"%s\">%s</span>
    who should be translated to:
    Benachrichtigung <span class=\"%s\">%s</span>

    Be aware that poEdit uses different colors to indicate you the translated strings, the untranslated strings AND the fuzzy strings wich are approximative translation. These fuzzy strings must be double checked and validated or modified to work.

    Example: difficult to see sometimes the subtle difference between “%s” and “count” when reading too fast ! ๐Ÿ˜‰

Viewing 25 results - 351 through 375 (of 1,142 total)
Skip to toolbar