WordPress.org

Ready to get started?Download WordPress

Forums

BuddyPress Group Email Subscription
[resolved] Localization problem (32 posts)

  1. bluebird2
    Member
    Posted 3 years ago #

    I tried to create a localization file but it did not work.

    Loading Issue: Author is using load_textdomain instead of load_plugin_textdomain function. This may break behavior of WordPress, because some filters and actions won't be executed anymore.

    http://wordpress.org/extend/plugins/buddypress-group-email-subscription/

  2. Dwenaus
    Member
    Plugin Author

    Posted 3 years ago #

    thanks for the post - i'll fix this!

  3. bluebird2
    Member
    Posted 3 years ago #

    Thanks. PLease let me know so I can test that on my site.

  4. Dwenaus
    Member
    Plugin Author

    Posted 3 years ago #

    this change will be going live with version 2.7.5 of this plugin. thanks @bluebird2

  5. willcast
    Member
    Posted 3 years ago #

    Is there any spanish translation for this plugin?

    Thanks,
    Will

  6. stefrusso
    Member
    Posted 3 years ago #

    Hi.. any news on the update with the localization bug fixed? I've made an italian .mo file and the language isn't loading, can't figure it out...

    thanks for any help from anyone.

  7. Dwenaus
    Member
    Plugin Author

    Posted 3 years ago #

    please email me your italian version to deryk@bluemandala.com so I can include it in the next release. In versino 2.7.6 i made an error implementing the above code and just foolishly replaced the function with the new one, but the arguments are quite different. @stefrusso if you want to test your file go to file bp-activity-subscription.php and one line 41 change load_plugin_textdomain back to load_textdomain. that will work,

    or you can try the better fix which is to change that whole function to

    function activitysub_textdomain() {
    	load_plugin_textdomain( 'bp-ass', false, dirname( plugin_basename( __FILE__ ) )$mofile );
    }
    add_action( 'init', 'activitysub_textdomain' );

    let me know if the second solution works.

  8. stefrusso
    Member
    Posted 3 years ago #

    I tried both but neither worked. it might help if you were more specific (i'm not a programmer) on the second suggestion: if you tell me exactly what code to replace with the new code I'll try again.

    thanks...

  9. Dwenaus
    Member
    Plugin Author

    Posted 3 years ago #

    in a few minutes version 2.7.7 will be available so try it then. @stefrusso

  10. stefrusso
    Member
    Posted 3 years ago #

    you're awesome... ;)

  11. Dwenaus
    Member
    Plugin Author

    Posted 3 years ago #

    awe shucks :)

    hey, why not rate the plugin at wordpress.org
    http://wordpress.org/extend/plugins/buddypress-group-email-subscription/ or consider a donation :)

  12. Frank Senftleben
    Member
    Posted 3 years ago #

    Hi from Germany

    I translate with the prg localisation, and i have the po and mo file in german.

    but not working, YES i have the version 2.7.7

    and the mo and po file have the name:

    bb-ass-de_DE.mo and
    bb-ass-de_DE.po

    DONT´T work !!

    Please help !

  13. chestnut_jp
    Member
    Posted 3 years ago #

    Hi Frank,

    Please replace the line 36 in bp-activity-subscription.php, as following:

    [ Original ]
    load_plugin_textdomain( 'bp-ass', false, dirname( plugin_basename( __FILE__ ) ) );

    [ Changed ]
    load_plugin_textdomain( 'bp-ass', false, dirname(plugin_basename(__FILE__)).'/languages' );

    OR

    load_plugin_textdomain('bp-ass', PLUGINDIR.'/'.dirname(plugin_basename(__FILE__)).'/languages');

    This is because the original difines the place of the plugin but not the place of "languages" folder.

  14. stefrusso
    Member
    Posted 3 years ago #

    I tried this fix and it doesn't work, I get an error and the site won't load.

  15. chestnut_jp
    Member
    Posted 3 years ago #

    Hi stefrusso,

    Do you use 2.7.7?
    My fix is subject to 2.7.7.

    If you use 2.7.7 and my fix do not work, probably you make some typos, for example, lacking ";" at the end of line or so.

    Sometimes copy and past from this topic make extra blank or something like that, so please take time to change it manually.

    My fix work on my site.

  16. chestnut_jp
    Member
    Posted 3 years ago #

    P.S.
    From 2.7.7, the name of language files should be bp-ass-$locale.mo(po).
    The files included 2.7.7 were old, as their names begin with buddypress.

    So, you might rename your italian lang files to bp-ass-it.po and bp-ass-it.mo.

  17. Frank Senftleben
    Member
    Posted 3 years ago #

    YES !

    Now it´s working !

    I have to make a NEW - Localisation - file and now it´s working !

    Thank YOU !

  18. stefrusso
    Member
    Posted 3 years ago #

    still not there, but I'm faithful!

    so... I'm naming my .mo and .po files bp-ass-it.mo (po)

    I've got the latest version of the plugin running.

    nothing happening yet.

    I noticed that 2.7.7 still has the language files named wrong.

    I also tried making a brand new .po from the .pot provided in 2.7.7, and then changing the name to bp-ass-it.po .... still nothing

    Any tips? I can't wait to be where you guys are... :) This is such a cool plugin, worth a donation.

  19. stefrusso
    Member
    Posted 3 years ago #

    I'm happy to announce success!

    It was necessary to change the name of the .mo file to bp-ass-it_IT.mo, using the extra _IT at the end.

    thanks to all for the kind support.

  20. willcast
    Member
    Posted 3 years ago #

    Hello,

    What about spanish? Where can I find the language files... or what should I do to translate it for this matter?

  21. thosch
    Member
    Posted 3 years ago #

    @Dwenaus Thanks for a great plug-in and the fix for other languages @chestnut_jp. I just finished the Swedish translation.

  22. willcast
    Member
    Posted 3 years ago #

    ok, I think I managed to find a way to create a localization of the wordpress plugins (using POEdit) so this is my first attempt of localization (bear with me please)

    However, even when the DB_LANG of my WP is es_ES and I copied the attached files to:
    /wp-content/plugins/buddypress-group-email-subscription/languages

    ... the plugin still shows the English literals in my installation.

    Can you please tell what are the next steps I must take to make it shows the Spanish literals?

    All best,
    Will
    PS: By the way, I just sent to .mo and .po to the address mentioned above

  23. willcast
    Member
    Posted 3 years ago #

    Woohoo!!! I made it!

    For the record:
    I was NOT on 2.7.7 so I upgraded my plugin.

    Then, I changed the line 34 as mentioned above.

    I renamed my old buddypress-group-email-subscription-*.po/mo to bp-ass-*.po/mo

    An it worked like a charm!

    Thanks for you plugin.
    Will

  24. bluebird2
    Member
    Posted 3 years ago #

    I have the most updated version of the plugin and still it is not working properly. I changed "bp-activity-subscription.php" as chestnut_jp suggested. I also renamed the translation files to "bp-ass-fa_IR.po" and "bp-ass-fa_IR.mo". That fixed most of the problems with localization (to the developer: Please apply those changes to the next update of the plugin.)

    The only remaining issue is in my group page the translation for "Email Options" does not show up. Does anyone have a similar problem?

  25. Dwenaus
    Member
    Plugin Author

    Posted 3 years ago #

    This is now fixed - I should have tested this before the last update. Sorry about that. PLease email me all translation files so I can include them. I'll look into the Email Options bug. I believe that is set before translation occurs.

  26. Dwenaus
    Member
    Plugin Author

    Posted 3 years ago #

    Email options not showing up is not a translation issue - this happens with english also. It is a bug with WP 1.2.6! make these simple change to the core bp files to fix the issue: http://trac.buddypress.org/changeset/3374

  27. willcast
    Member
    Posted 3 years ago #

    I sent you the Spanish translation this weekend. Did you get it?

  28. Dwenaus
    Member
    Plugin Author

    Posted 3 years ago #

    I got the spanish, and it will be in the next update. nice work!
    I've fixed the issue with the Email Options not translating. I changed it to Email Notifications and am getting Buddypress to translate it because it's already part of buddypress. quick fix.

  29. Dwenaus
    Member
    Plugin Author

    Posted 3 years ago #

    actually, I found a work-around for the Email Options and now it is translatable. It ended up being a tiny bug in BP.

  30. bluebird2
    Member
    Posted 3 years ago #

    Thanks. Would you tell us what that bug in BuddyPress 1.2.6 is and it can be fixed?
    I have the exact same problem with BuddyPress-Links plugin.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic