Closed Dartui closed 6 years ago
Hi! @Dartui Thank you for reporting! And I'm sorry for forgetting about locale switcher!
I wrote a code for switching locale by user setting, and will dig more into pairing of different WordPress locale codes.
@Dartui It looks this ☝️ change also fixed 2 type locale code problem as well. I'll update a plugin on wordpress.org shortly, so please test it on your site :)
Oops now I understand the problem, wait a moment!
@Dartui It works now :) Can you test on your site? Thanks!
@mayukojpn everything works great, thanks a lot!
Hi, let's take Gutenberg plugin and Polish locale as an example.
If we change
$locale
variable in plugin topl
, we will have this URL to download translation:This is totally correct, but will store it into
gutenberg-pl.mo
file. WordPress will not recognize it, because for Polish language the locale slug ispl_PL
.There are also another languages, which has two "segments" in locale. On GlotPress there are separated with dash, but WordPress requires underscore as separator (
en-gb
vsen_GB
)