you are logged in as: $a

you are logged in as: $a

por seaghan moriarty -
Número de respostas: 7


Does anyone know if the error below might be caused by an incomplete language pack?

Behaviour

When logged in (English) it says You are logged in as Admin User
When logged in (Polish) it says Jesteś zalogowany(a) jako Admin User
When logged in (German/French/etc.) it also says ................. Admin User

However, when logged in (Gaeilge - Irish/GA) it says: Tá tú logáilte isteach mar: $a
In other words, most languages show Firstname Lastname, but while using Gaeilge/Irish it only shows $a

Can anyone suggest what might be wrong?  thanks!! 


Média das avaliações:  -
Em resposta à seaghan moriarty

Re: you are logged in as: $a

por Juho Jaakkola -

Yes, there's probably something wrong with the Gaeilge language file. Open the language file and look for this:

$string['loggedinas']

For example in the English language file it has the following value:

$string['loggedinas'] = 'You are logged in as {$a}';

Note that $a has curly braces around it. One reason may be that those are missing from the Gaeilge language file.

Média das avaliações: Useful (1)
Em resposta à Juho Jaakkola

Re: you are logged in as: $a

por Helen Foster -
Imagem de Core developers Imagem de Documentation writers Imagem de Moodle HQ Imagem de Particularly helpful Moodlers Imagem de Plugin developers Imagem de Testers Imagem de Translators

Juho is correct - the problem is indeed caused by missing curly braces.

I found the string and contributed a fix for it on the Moodle translation site. Hopefully one of the Irish language pack maintainers will accept it soon. In the meantime Seaghan you can use the Language customisation feature in Moodle (Administration > Site administration > Language> Language customisation) to quickly fix it on your site.

Média das avaliações: Useful (2)
Em resposta à Helen Foster

Re: you are logged in as: $a

por seaghan moriarty -
Thanks for your help.


I have updated the local customisation text to "Tá tú logáilte isteach mar: {$a}"  for the Irish language pack (Administration -> Site administration -> Language customisation), however now in the top bar I am getting the text "Tá tú logáilte isteach mar: $a->firstname $a->lastname".

It doesn't seem to be recognising $a as an object?


Em resposta à seaghan moriarty

Re: you are logged in as: $a

por Tim Hunt -
Imagem de Core developers Imagem de Documentation writers Imagem de Particularly helpful Moodlers Imagem de Peer reviewers Imagem de Plugin developers

I think the problem is that the string has been translated as

"Tá tú logáilte isteach mar: $a->firstname $a->lastname"

and it needs to be

"Tá tú logáilte isteach mar: {$a->firstname} {$a->lastname}".

Média das avaliações: Useful (1)
Em resposta à Tim Hunt

Re: you are logged in as: $a

por seaghan moriarty -

thanks so much Tim!

I'll try that shortly, but looks good sorriso

Em resposta à seaghan moriarty

Re: you are logged in as: $a

por Helen Foster -
Imagem de Core developers Imagem de Documentation writers Imagem de Moodle HQ Imagem de Particularly helpful Moodlers Imagem de Plugin developers Imagem de Testers Imagem de Translators

Thanks Tim from me too. sorriso

I just checked and found the ga string fullnamedisplay | core needed changing from

$a->firstname $a->lastname

to

{$a->firstname} {$a->lastname}

I again contributed a fix for it on the Moodle translation site. Hopefully one of the Irish language pack maintainers will accept it soon.

Média das avaliações: Useful (1)