0

We are using strings for localisation support.

  1. Some of these have parameters for eg. "My name is {0} and I am version {1}.0."
  2. Another scenario is we have broken strings like "My blah blah is "+ "Yada Yada ..."+ "Tom, Harry ... are all pals"

Would these cause problems if we have to translate these to languages like japanese and chinese ?

Please note we have frequent releases and the translation guys id both as requiring much effort for every release.

1 Answer 1

1

Using substitutions like {0} is often preferable because of word ordering.

To give a trivial example, the translation of something like "Please save the file" from English into German might look like "Please the file save". In that case the English string might be:

"Please {0} {1}"

while the German can be

"Bitte {1} {0}"

(Forgive my poor knowledge of German, but you get the idea!) In both cases the code can be:

do_substitution(text, verb, object);
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.