• Resolved milkpainter

    (@milkpainter)


    Hi and thanks a lot for this great plugin !

    I’m displaying image credits after every post. My posts are written in my native language : French.
    Unfortunately, the credits look like this :
    “Images courtesy of xxxx and xxxx”.

    Would it be possible to make this sentences translatable in the plugin ?
    (For information, in French it would be :”Photos réalisées par xxx et xxx”).

    https://wordpress.org/plugins/media-credit/

Viewing 12 replies - 1 through 12 (of 12 total)
  • Plugin Author pepe

    (@pputzer)

    Yes and no. There is a filter hook (media_credit_at_end) you could use to replace the credit with a translated version. And of course if someone decides to translate the plugin into French, the image string would be translated as well 🙂

    Technically, it would be possible to another setting to the options. However, to get a proper credit string in all circumstances gets complicated very quickly (i.e. what if there is only one image?). The translation system used by WordPress handles these vagaries, whereas a manually entered format string would not.

    Thread Starter milkpainter

    (@milkpainter)

    Hi,

    Traditionally, for the plugin to be “translatable”, all the strings in the plugin have to be “extracted” to be ready for the GNU gettext framework.

    For e.g., this article talks about this.

    I understand this is more complicated than letting the user override media_credit_at_end, but this would be appreciated by users of different countries.

    Plugin Author pepe

    (@pputzer)

    Yes, of course. Media Credit is already fully internationalized, someone just needs to provide a French translation. Since WordPress now provides a standardized language pack infrastructure for plugins, we currently don’t ship the .pot file anymore.

    Thread Starter milkpainter

    (@milkpainter)

    Thanks for your answers ! And I apologize, I just didn’t know about translate.wordpress.org, sorry to bother you…

    Plugin Author pepe

    (@pputzer)

    No bother at all! I never really thought about that string – it’s indeed a pain if you are not using one of the translated languages (currently only German). If you are interested in doing a French language pack for Media Credit, I can get you access as a PTE (project translation editor) for the French translation. (Be warned however, that language packs are only generated when 95 percent of the plugin strings have been translated, though thankfully the README strings are not included in that limit.)

    Thread Starter milkpainter

    (@milkpainter)

    I just translated some strings for the “Development (trunk)” for the fr_FR language.
    I’m interested in being a project translation editor for the plugin !

    Plugin Author pepe

    (@pputzer)

    Done. Not sure how long it will take for the request to approved, though. Probably within a few days.

    Plugin Author pepe

    (@pputzer)

    OK, looks like the French translation community works a bit differently. Please have a look at https://fr.wordpress.org/2015/12/18/how-french-community-handles-pte-requests/. Apparently, they do like to checkout your work before giving PTE status. Oh well.

    Thread Starter milkpainter

    (@milkpainter)

    It looks a little bit complicated 🙂

    Hope at least my translations will be approved by another PTO…

    Thread Starter milkpainter

    (@milkpainter)

    Translation in french is done and available 🙂

    Plugin Author pepe

    (@pputzer)

    Great! Thank you!

    Plugin Author pepe

    (@pputzer)

    @milkpainter: Sorry, wrong plugin *doh*

    • This reply was modified 7 years, 3 months ago by pepe.
Viewing 12 replies - 1 through 12 (of 12 total)
  • The topic ‘Translation’ is closed to new replies.