@stephanemartinw,
Do you know how user’s preferred language is saved in database? If yes tell me and we see how it can be done.
I think it’s just another user meta to import (a column to add to csv file), ‘locale’ seems to be the meta_key.
Correct ?
If this is the meta correct… yes.
I don’t know how it works. I know how my plugin works: new column, new key and if it is correct for your purpose it will work.
hi,
I’m trying to help by doing a test run. I poked around and then saw what happened in the database. Here’s what I found.
First, “Users” > “Edit User” > “Language” was set to “Site Default”, and in the database dump was this:
INSERT INTO 'wp_usermeta' VALUES ...,('33','2','locale',''),...;
Then, “Users” > Edit User -> Language -> (switch to Brazilian Portugese), and in the new database dump showed this:
INSERT INTO 'wp_usermeta' VALUES ...,('33','2','locale','pt_BR'),...;
-
This reply was modified 9 years, 3 months ago by
mjassen (mjjojo). Reason: correct backticks escape syntax
@mjjojo,
Thank you very much!
So @stephanemartinw the solution is:
* Column: locale
* Value: pt_BR
For example 🙂
Hello,
Thank you both for your help!
I’ve tested and it works.
Just on thing : on the profile page, at bottom, a :
Extra profile information
locale fr_FR
is added to the page, but is a duplicate info because the preferred language above is correctly filled.
A way to avoid this ?
Thanks again.
Best regards,
Stephane
Stephane,
I have to include it as a field that must not be shown.
In next version it will be included.
Great support! Thank you !
Please remind the good review or a little donation please 🙂