Hi everyone
just a small question to all the multi lingual users out there or to any one who knows…
We have just recently been requested to quote for a site that will contain multiple languages these being Russian Chinese Arabic and English…
So the same website will be produced in the above specific languages but sections within the languages will be in-dispersed with technical elements which will probably be in English.
Has any one had to set up a site with this sort of scenario and what was your experience eg. pit-falls unforeseen complications?.. apart from the obvious like things won’t fit due to text contraction or expansion.
I usually don’t pick up such old threads, but allow me to take the opportunity to do (cause I have this question currently in my german forum board as well). Did you solve it or did it come to this project? And how did you handle it?
Basically I always think about the following mechanism (where I’m neither sure if it would work nor if it makes sense at all):
Assumed we already created the rock-solid super adaptive framework. In this Framework and in each DIV dedicated for text, there is a conditional loading query thing which is called:
"If a user from Russia calling this page, load “textsnippet1-ru.txt” - "If a user from France calling this page, load “textsnippet1-fra.txt” and so on.
All text can be created and organized within Freeway in a Subfolder structure and will be linked back to its dedicated places.
Is this a mad idea or by any chance thinkable. And if not - where is my fallacy? Or is it already possible and you call it Ajax?
Essentially yes. For example, using MODX it’s possible to dynamically and seamlessly link between any number of language translations, allowing the user to select the one they want. The implementation is actually pretty slick.
I built this a number of years ago, no idea how much effort it would be to install if your Apache doesn’t have the module included already. ContentNegotiation - ActionsForge
The downside to this is that it is creating an entire replacement page for each language, not the parameter replacement that you are envisioning in your question. The example that comes to mind of that is Rails, which has internationalization baked in at the very lowest level, and you can define and replace placeholders very easily using strings loaded from a YAML file (simple text format that can express multi-dimensional data structures).
en:
hello: "Hello world"
es:
hello: "Hola mundo"
In your view, you would just put <%=t :hello %> and the framework would take care of loading the appropriate value into the template at the moment the page is viewed, using the same browser preferences as the ContentNegotiation Action does. If you didn’t want to trust the browser, you can override the language constant in your application.