• Hi guys, I am having my website (including Polylang) developed by an external developer, and I have a question about the way languages are supported.

    My site is a comics website, and I am going to support multiple language transations of my comics. The way which my developer has told me to enable this is to ensure the category slug for each language reads “comics_en”, “comics_zh”, “comics_pt”, etc.

    I have tried category names such as “comics_ptbr” (i.e. specifying Brazilian Portuguese) and “quadrinhos_pt” (Quadrinhos is the pt-BR translation of the word ‘comics’), but these do not successfully result in my comics appearing in the appropriate formatting on my site. (The developer has created some CSS/etc for the way the comics images display within my website).

    It seems that this current setup is preventing me from having more than 1 language with a certain language code. e.g. if I have Brazilian Portuguese (pt_BR), I would not be able to also feature standard Portuguese (pt_PT).

    My question is: is this limitation to using the 2 letter language code a limitation of Polylang, or just the way the plugin is currently implemented on my site.

    I ask this question because I want to future-proof the code of my site. So that (for example) I might one day support both Brazilian Portuguese (pt_BR), and standard Portuguese (pt_PT) versions of my comics.

    https://www.ads-software.com/extend/plugins/polylang/

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Chouby

    (@chouby)

    Currently, the most important for Polylang is the WordPress locale (in your case pt_PT or pt_BR), because it’s the code use to load the right translation.

    For the language code (unique to a language), you could technically enter what you want even if it’s good practice to use ISO language code. However Polylang does currently limit the number of characters to 2 or 3 (to support 2-letters ISO 639-1 and 3-letters ISO 639-2 and ISO 639-3 language codes).

    It seems that (unlike WordPress locale) ISO does not distinct Brazilian portuguese from Portugal portuguese (not even with ISO 639-2 or ISO 639-3). So to distinguish both languages, you will have to use non ISO code (2 or 3 characters), unique for each language.

    Thread Starter stuartmcmillen

    (@stuartmcmillen)

    Gotcha. Thanks for the response.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘[Plugin: Polylang] Multiple languages sharing two letter language code (e.g. pt_BR and pt_PT)’ is closed to new replies.