Posts: 3,436
Name: Thierry
Location: I'm the uber Spaminator !
|
Quote:
|
Maybe Google translation be an option?
|
No, not rerally.
At least, not if you want not to look like a 4 year old...
i live in a country who have 4 officals languages (German, Italian, French and a small dialect mixing all of them), so it's fairly the norm here.
Usually, what you want is to replace the simple texts with a call to a function that will output that text.
I have a library (fairly clumsy, and who would need a good rewrite) that was storing translations in 1 master tranlation file, and had 1 additional file per site page for each language.
Simple word like "man", "woman", "yes","no" and such where defined in the master file.
The "local" file was defining translations that would not occure elsewhere, or full sentences.
If something was present in both file, the "local" value would override the "global" one
Then, I had a simple $_SESSION['LNG'] variable that would hold the ISO code of the language (fr for french, de for german, it for italian, en for english...) and the library would output the translation for a given key:
Code:
english file:
confirm=Are you sure you want to log out?
French:
confirm=Etes-vous certain de vouloir vous déconnecter?
German:
Sind sie sicher sie wollen sich auslogen ?
My german is pretty bad, my apologies for any german speaking person around here....
If you are curious, the biggest usage htat is done of this library today is on www.swissfriends.ch
__________________
Only a biker knows why a dog sticks his head out the window.
Last edited by tripy; 12-20-2008 at 12:29 PM..
|