[Mageia-sysadm] mediawiki

Buchan Milne bgmilne at staff.telkomsa.net
Fri Feb 25 14:05:25 CET 2011


On Thursday, 17 February 2011 21:22:39 Michael Scherer wrote:
> Le jeudi 17 février 2011 à 20:42 +0200, Buchan Milne a écrit :
> > On Thursday, 17 February 2011 17:56:23 Michael Scherer wrote:
> > > Le jeudi 17 février 2011 à 17:32 +0200, Buchan Milne a écrit :
> > > > On Thursday, 17 February 2011 12:40:51 Buchan Milne wrote:
> > > >       1 i-default
> > 
> > I've added some debug logging (see patch below).
> > 
> > Firefox, to which I have added a number of languages, shows:
> > 
> > [info] Languages: en-za,en-gb,en-us,en,af,nl,i-default, default: af,
> > saving: en-za

I have added some rule-based changes to the language (e.g. fr-fr -> fr), but 
allowing en-us,en-gb,pt-br,no-.*,xh-.*.

The problem here is that, say we don't have or allow en-za, the user would 
want en-gb, but instead we currently heuristically give en.

So, I think to solve this and prevent invalid values for preferredLanguage, it 
may be better to have language mapping entries in LDAP, e.g.:

dn: supportedLanguage=en-gb,ou=Languages,cn=CatDap,ou=Settings,$suffix
supportedLanguage: en-gb
preferredLanguage: en-gb
preferredLanguage: en-za
preferredLanguage: en-ca

or similar. Then, CatDap and slapo-constraint could use the same data.

So, it may be time to start working on some LDAP schema ... so we will need to 
register an IANA Enterprise number at some stage.

> > (So, in this case, the interface is displayed in Afrikaans ... I guess I
> > need to create at least 3 English translations - en, en_us, en_gb)
> > 
> > Chromium with default language settings shows:
> > 
> > [info] Languages: en-gb,en-us,en,i-default, default: en, saving: en-gb
> > 
> > So, I can imagine a case where it is the only language listed. In this
> > case, I think we should either not set preferredLanguage, or set it to
> > en.
> 
> I would set it to en. Not setting a default one just push the decision
> of using default on every consumer of the information, and that doesn't
> sound good.
> 
> > > >       1 es-pe
> > > >       1 cs-cz
> > > 
> > > Theses 3 one are likely wrong ( according to IANA registry )
> > 
> > Do you have a URL handy?
> 
> http://www.iana.org/assignments/language-subtag-registry
> 
> Fact is there is several registry of language ( like 6 iso standards +
> ietf one ), so people can easily have it wrong ( not to mention people
> who get it wrong with tld and country )
> 
> > > > I guess I should filter these out, and replace with
> > > > en,fr,es,ru,it,fi,et,es,tr ? I will fix the wrong ones in LDAP later.
> > > 
> > > How can we enforce correct entry ? Should we maybe have a whitelist,
> > > and receive a monthly mail about wrong one ?
> > 
> > May be a good idea. Or, we could use slapo-constraint (with regex, or
> > dynamic list in LDAP)
> 
> We could feed the list from the one of tx
> ( http://www.transifex.net/languages/ but in a more exploitable, I
> assume this can be downloaded somewhere ).
> 
> > Maybe we should also compare to what localisation teams we have (or don't
> > have), and indicate to users whose preferred languages isn't localised
> > that they could contribute in that way.

Yes, maybe we can push the languages we have into LDAP, and for all languages 
not there, display a notice in CatDap that the interface is not in their 
language due to not having a localisation team?

> Yup, nice idea. I was also about to think how we should manage i18n team
> in ldap, and if this is needed. This would requires to have the
> delegation feature working in catdap ( not sure of the status of this ).

Regards,
Buchan


More information about the Mageia-sysadm mailing list