A Quick Intro To Sitecore and Languages
Posted 05/10/2016 by Ed Kapuscinski
I was recently asked a question about Sitecore and languages and I realized that the Sitecore community as a whole might appreciate the same info.
Sitecore was, from the ground up, built to support multiple languages. I suspect this is because it came out of Northern Europe, where being multi-lingual is much more common than in the United States. Therefore, its multi-language and multi-culture aspects are as well thought out and easy to use as the rest of the product.
Sitecore uses a concept of "Language Variants". You can think of these as "dimensions" of content, where any piece of content in the content tree can exist in multiple languages. Each of these language variants exists as a discrete thing in the system, so it can move through workflow, have versions, etc... as necessary. A language variant can exist not only for each language, but also for culture/language pairings. This way, you can serve up different french versions for Canada and France (the major difference, I've read, is the cursing). This is handy in situations where not only does the dialect need to change, but often the content as well.
The content in these versions is made up of fields (title, teaser, main image, etc...). These fields can either be language dependent (you'd usually want your text fields to belong to the language so they can be translated), or non-language dependent (sometimes you want to maintain relationships or use images that are the same across languages).
When it comes to translation, there are numerous options. Sitecore doesn't have automatic translation capabilities built in, meaning humans must do the translation, but it can be integrated with external translation systems using the XLIFF standard to hand content off and to bring it back in after it has been translated.
On the display side, a user has what's called a "context language". This can be set in a number of ways and is how Sitecore knows what language version to show a user when they request content. Usually, changing the context language has been done by including the desired language in the URL. http://www.nttdatasitecore/en/Case-Studies would get you english, and http://www.nttdatasitecore/fr/Case-Studies would get you french.
The biggest historical problem is that, for a given language, if an item doesn't have a version in the current context language, Sitecore wouldn't show that item to users. That's changed with Sitecore 8.1 (the current lead version) though, and it now has a concept of language fallback (so that if a version isn't available in the context language, it will serve up a version in the default language instead).
Hopefully these few paragraphs will make it easier for those of you who have to quickly learn about Sitecore's language capabilities to start figuring out what you need to do to start taking advantage of them.