iOS localization inconsistency
Posted
by
Joe Völker
on Stack Overflow
See other posts from Stack Overflow
or by Joe Völker
Published on 2011-03-10T16:08:46Z
Indexed on
2011/03/10
16:10 UTC
Read the original article
Hit count: 328
I'm localizing an iPhone app for the first time. I've put all my strings into a Localizable.strings
file, accessing them via NSLocalizedString
from within my code. Works fine.
Next, I have a file called info.html
that contains the flesh of a UIWebView
that I use as an About box. I've put it in the language folders (en.lproj
and de.lproj
), and added them to my Resources in Xcode.
Now, in Simulator, both the Strings, and the html file display in the appropriate language.
However, on the device, the Strings appear localized while the html file remains untranslated.
This is a strange inconsistency between Simulator and Device! Anybody know of a workaround? (...other than defying the localization system, and using NSLocalizedString
to call de_info.html
, en_info.html
etc. by hand.)
© Stack Overflow or respective owner