How to perform Localization using sqlite stored data-iOS App? -
in app doing localization support mutiple languages. creating .string file , using following method:
-(nsstring*) languageselectedstringforkey:(nsstring*)key;
i using key_value concept this. working fine. question is:
let have sqlite database has different languages string needs localized.
for eg: for spanish
"username" = "nombre de usuario"; "password" = "contraseƱa"; "submit" = "presentar";
for french
"username" = "nom d'utilisateur"; "password" = "mot de passe"; "submit" = "soumettre";
all insert in sqlite database.
how can perform localization app way?
since seem have strings traduction within 1 db, need have intermediate data structure act bridge between db , method localize string.
you make use of dictionary
e.g store key string identifier , value array contain languages traduction. need feed data structure once then.
note recommended way use .strings
files localisation need provide raison why can't take approach.
Comments
Post a Comment