Changes for page UTF-8 Encoding Tips

Last modified by Ray Kiddy on 2022/01/11 21:36

From version 15.1
edited by Antoine Berry
on 2012/09/20 10:31
Change comment: There is no comment for this version
To version 16.1
edited by Antoine Berry
on 2012/09/20 10:32
Change comment: There is no comment for this version

Summary

Details

Page properties
Content
... ... @@ -1,6 +1,6 @@
1 1  = UTF-8 Encoding Tips =
2 2  
3 -Encoding questions are asked frequently on the mailing list. This is just a collection of tips for using UTF-8. It's a checklist of sorts. Make sure you've done all the things specified here before pitching your computer into the ocean :)
3 +Encoding questions are asked frequently on the mailing list. This is just a collection of tips for using UTF-8. It's a checklist of sorts. Make sure you've done all the things specified here before pitching your computer into the ocean :-)
4 4  
5 5  == Check your database ==
6 6  
... ... @@ -35,7 +35,7 @@
35 35  
36 36  == Use Project Wonder ==
37 37  
38 -I think this goes without saying but: **Use Wonder**. Set encoding in the properties file. Notice it is UTF-8 with a hyphen. It it always UTF-8 with a hyphen... well, except with the MySQL image above because they excel in doing things differently :)
38 +I think this goes without saying but: **Use Wonder**. Set encoding in the properties file. Notice it is UTF-8 with a hyphen. It it always UTF-8 with a hyphen... well, except with the MySQL image above because they excel in doing things differently :-)
39 39  
40 40  {{noformat}}
41 41  
... ... @@ -55,12 +55,16 @@
55 55  
56 56  {{/noformat}}
57 57  
58 -== Localizable strings should be in UTF-16! ==
58 +== Localizable strings should be in UTF-16 ==
59 59  
60 60  Localizable.strings should be encoded in UTF-16. The localizer can detect UTF-16 without error, where it can confuse UTF-8 with other encodings. Pascal says use UTF-16LE if you want to be explicit about things... Especially if you are editing your strings files in an external editor like BBEdit or whatnot. I use the eclipse editor and UTF-16 myself and all seems to work fine for me. So to each his own.
61 61  
62 -== Build your files in UTF-8. ==
62 +== Build your files in UTF-8. ==
63 63  
64 64  If you have some special characters in your code (like '€' for exemple), then you will need to specify which encoding you want when you build your application. To do that, you have to modify your "build.xml" file by adding the property "encoding="utf-8" into your <wocompile> statement.
65 65  
66 - <wocompile srcdir="Sources" destdir="bin" encoding="utf-8">
66 +{{code language="xml"}}
67 +
68 +<wocompile srcdir="Sources" destdir="bin" encoding="utf-8">
69 +
70 +{{/code}}