Need help with a multilingual Buddypress site

Anyone have some clear instructions on how to setup a multilingual Buddypress site that also incorporates a RTL language such as Arabic?

I've tinkered around with WPML, but it wasn't all that clear to me.

Any help or a shove in the right direction would be greatly appreciated.

Thanks

  • Chris
    • The Bug Hunter

    I've had a look. The general feedback seems to be that the out of the box stuff isn't quite doing it yet.

    Recommend posting this as well on the buddypress forums - maybe adding something on to any of these posts:

    http://buddypress.org/community/groups/localization/forum/topic/how-to-do-arabic-translation/
    http://buddypress.org/community/groups/creating-extending/forum/topic/buddypress-multilingual
    http://buddypress.org/community/groups/how-to-and-troubleshooting/forum/topic/wpml-org-bp-multilingual-plugin-support-1

    That said, take us through where you are up to, and we can do our best to help you.

  • Philip John
    • DEV MAN’s Apprentice

    Hiya!

    WPML does seem to have a bit of a learning curve but they do provide a good bunch of guides and the folks there are super helpful in my experience.

    Perhaps give it another go? Otherwise, I think you probably are left to providing your own translations using Poedit or similar, the manual way.

    Phil

  • Mark
    • New Recruit

    Got it working...funny how persistence pays off.

    Just in case anyone else encounters the same issues...
    If you have a right to language and you want your theme's text-decoration to change when the language is selected just put this code in header.php:

    <link href="<?php if (ICL_LANGUAGE_CODE =='your_language_code'): bloginfo('stylesheet_directory');?>/rtl.css<?php else: bloginfo('stylesheet_url'); endif;?>" rel="stylesheet" type="text/css" />

    Obviously, you would change "your_language_code" to the two-letter language of your choice.

    On the Backend
    Make sure that you have the languages .mo files for all your languages. You will need .mo files for wordpress and also for buddypress. The wordpress files can be found at here. I just downloaded wordpress in the language I wanted and retrieved the language .mo file from wp-content > languages folder and dropped it into the corresponding folder of my wordpress install.

    Buddypress also has to have translation .mo files. They can be downloaded from here. I had some trouble downloading the files...so I just copy and pasted the content into a text editor and resaved it, maintaining the correct buddypress-xy-Xy.mo format. These language files must be put into wp-content > buddypress > bp-languages.

    For Right-To-Left (RTL) Languages
    I had trouble getting my admin to switch orientation from LTR to RTL....fortunately there was an easy solution. If your language is RTL you have to create an additional .php that will live in the wp-content > languages folder. This file will look like this:

    <?php
    
    // Arabic Text Direction
    
    $text_direction = 'rtl';
    
    ?>

    I would name this file the same as the name of the .mo language file. So if my language file is "ar.mo" then this file would be named "ar.php". Just remember they have to be in the same directory - wp-content > languages.

    Now all you have to do is choose which language you want the admin to be on your user profile page.

    If your language translation for WordPress or BuddyPress is incomplete and you would like to translate it yourself by downloading the language's .po. This file should be in the same place the .mo file was. Install a program like "Poedit" and open the .po file and translate away. Upon saving it will generate the .mo file.

    Hopefully this helps someone who has a similar problem.

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.