Forum LAMS for Tech-Heads - General Forum: Re: Re: Re: locale of users from moodle integration


 
Search: 

4: Re: Re: Re: locale of users from moodle integration
In response to 3 02/11/08 02:23 PM
[ Reply | Forward ]
Hi Glen,

> I have tried both things you suggested, setting moodle user language to Maori, and also editing the userinfo.php file to
> pass through mi, and in both cases when the lams user is created it still gets the default english language.

When a Moodle user gets to a LAMS lesson, the first thing LAMS does is to check whether the user does also exist in LAMS. If it doesn't, then LAMS calls the userinfo.php in Moodle to get info about the user. This userinfo request will return the basic user information so LAMS can generate the user. For the language, LAMS will use the country and language code to set the default language for this particular user.

Now if you change the default user language in Moodle *after* it was already created in LAMS, then in LAMS this user will still have the original language that he/she was created with. If you want to change existing users, you might need to run the sql script I mentioned before.

Yesterday I tried this creating a user from scratch in the Moodle demo site and it seems to work fine.

You can give it a go by creating a user there with country as New Zeland and then in the user's profile change the name to Maori, and you will see than after that, whenever you access LAMS, the LAMS interface will be Maori.

BTW, are you using LAMS 2.0.4, right?

Thanks,

Ernie

Posted by Ernie Ghiglione

5: Re: Re: Re: Re: locale of users from moodle integration
In response to 4 02/11/08 05:45 PM
[ Reply | Forward ]
Thanks again. This is one of those frustrating issues - should just work, but isn't ...

I went to the test server you mention and yes it all works as stated, but when I create a brand new users on our moodle server and set the country to NZ and language to Maori, and then add a new lams activity with that user it gets the default language of English Australian on LAMS. I have also tried with existing users by deleting their lams user account and then adding another lams sequence in moodle, and again the new account it creates is English.

The only difference I can spot in our installation is the moodle language pack is mi_wwwow and on your server it is mi_tn, but userinfo.php only sends through the mi part of the langauge pack string anyway.

Yes we are on LAMS 2.0.4 and Moodle 1.8.3

Any other ideas?

Thanks
Regards
Glen

Posted by Glen Davies

Reply to first post on this page
Back to LAMS for Tech-Heads - General Forum