IOS localization inconsistency

This is the first time I have localized an iPhone app. I put all my lines in a file Localizable.strings, accessing them through NSLocalizedStringfrom my code. Works great. Then I have a file with a name info.htmlthat contains the flesh UIWebView, which I use as the About box. I placed it in the language folders ( en.lprojand de.lproj) and added them to my resources in Xcode. Now in Simulator, both strings and html files are displayed in the corresponding language. However, on the device, the lines are displayed localized, and the html file remains untranslated.

This is a strange inconsistency between Simulator and Device! Does anyone know of a workaround? (... besides ignoring the localization system and using it NSLocalizedStringto call de_info.html, en_info.htmletc.).

+3
source share
2 answers

Try uninstalling the application first.

When you use Xcode to deploy to a device (or simulator), resources are added, not deleted.
Most likely, now you have three html files. One in the folder de, one in the folder enand one in the root folder.

And if he is there, iOS prefers one in the root folder.

As a rule: when you delete (or in this case move them) resources from your project, you must remove the application from the device or simulator.

+7

: , ( ).

XCode "alt" "Build", .

. ...

+4

All Articles