Globalization: getting current item translations

Topics: Developer Forum
Sep 3, 2008 at 10:40 AM
Hi libardo,

Is there any implemented method to get the current item translations? I've been looking at the code and I think that there isn't any public method for that.

Somehting like...
public IEnumerable<Translation> Translations {...}
defined in N2.ContentItem. That would be useful to create a menu with flags in the public site linking to the translation of the current page (ie. http://www.meteor.ie, look at the top-right)

What do you think?
Coordinator
Sep 3, 2008 at 6:15 PM
Yes, you can look at the language gateway: Engine.Resolve<ILanguageGateway>().FindTranslations(CurrentPage)

Nice. I like that it can grow to accomodate many languages.

Do you think it would be understandable to hide languages in a menu? I was thinking the current language could be shown and some cue to expand and get more. Something similar to http://dropit.se/