New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

language_chooser should contain the translated language names #2301

Closed
mightyiam opened this Issue Nov 9, 2013 · 5 comments

Comments

Projects
None yet
3 participants
@mightyiam
Contributor

mightyiam commented Nov 9, 2013

A language chooser should always display each language name in it's own language. For example:
English עברית

As of 2.4.3 the language_chooser gets translated so when we're on an English page we see:
English Hebrew

and on a Hebrew page we see:
אנגלית עברית

I've described how I've worked around this in Stack Overflow:
http://stackoverflow.com/a/19878140/359072

@henning

This comment has been minimized.

Contributor

henning commented Nov 11, 2013

+1 as that's a known good practice and naturally, one that needs a page in english might not recognize אנגלית
and one needing the page in עברית might not recognize "hebrew" :)

@digi604

This comment has been minimized.

Contributor

digi604 commented Nov 11, 2013

The solution is not to mark the language names for translation in your CMS_LANGUAGES:

LANGUAGES = (
('de', u'Deutsch'),
('en', u'English'),
('nl', u'Nederlands'),
('es', u'Español'),
('fr', u'français'),
('jp', u'日本語'),
)

@mightyiam

This comment has been minimized.

Contributor

mightyiam commented Nov 11, 2013

Exaclty, @henning .

@digi604 the language names are without a call to gettext. They are in the format that you showed. It still translates 'English' to the Hebrew 'אנגלית'. Why does it do this, even in English pages?
I tried specifying CMS_LANGUAGES and not just LANGUAGES because docs explain that CMS_LANGUAGES are generated from LANGUAGES in a format that does use gettext. So like I said, I specified CMS_LANGUAGES without gettext and it still translates. Help?

mightyiam added a commit to mightyiam/django-cms that referenced this issue Nov 24, 2013

@mightyiam

This comment has been minimized.

Contributor

mightyiam commented Nov 24, 2013

Don't mind my branch that mentions solving this. I'm not sure it does.

mightyiam added a commit to mightyiam/django-cms that referenced this issue Nov 24, 2013

@mightyiam

This comment has been minimized.

Contributor

mightyiam commented Nov 24, 2013

I don't know what I did wrong. It works as it should. Just don't translate the language names.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment