Last modified by Pascal Robert on 2015/05/04 04:24

From version 36.1
edited by Johan Henselmans
on 2009/11/10 06:49
Change comment: There is no comment for this version
To version 38.1
edited by tbritt
on 2009/11/06 10:18
Change comment: There is no comment for this version

Summary

Details

Page properties
Author
... ... @@ -1,1 +1,1 @@
1 -XWiki.johanhenselmans
1 +XWiki.tbritt
Content
... ... @@ -101,15 +101,8 @@
101 101  
102 102  {{/noformat}}
103 103  
104 -The other changes are then in the er.extensions.ERXLocalizer.availableLanguages and ERXLanguages:
105 -In the above case after adding canadian french these would change in:
104 +
106 106  
107 -{{noformat}}
108 -
109 -er.extensions.ERXLocalizer.availableLanguages=(English,Japanese,French_CA)
110 -
111 -{{/noformat}}
112 -
113 113  ===== Localized strings and components =====
114 114  
115 115  For each language available, you will need a corresponding Localizable.strings file. This file should be located in Projects->Resources->"Lang".lproj directory. In these directories, you'll store localized resources such as Localizable.strings files and localized components. So, continuing with the above example, you should create two new Localizable.strings files in the following places in your project directory:
... ... @@ -116,7 +116,6 @@
116 116  
117 117  Project->Resources->English.lproj->Localizable.strings
118 118  Project->Resources->Japanese.lproj->Localizable.strings
119 -Project->Resources->French//CA.lproj->Localizable.strings//
120 120  
121 121  As mentioned earlier, it's recommended that these be in UTF-16 format. You can do that by right clicking on the file in WOLips and selecting "Properties." In the resources panel, change from the project default encoding to UTF-16.
122 122  
... ... @@ -130,26 +130,6 @@
130 130  
131 131  and then right-click->Copy it from English.lproj and right-click->Paste it into Japanese.lproj. At this point, when you open the component in WOLips, there will be a tab at the bottom of the component editor view that allows you to switch back and forth between different localized versions of that component.
132 132  
133 -Your layout would end up something like this:
134 -
135 -[[image:ERXLocalizerLayout.png]]
136 -
137 -===== Localized EOAttributes =====
138 -
139 -In Wonder, it is also possible to localize attributes. There are two requisites:
140 -
141 -First add ERXLanguages to your Properties file:
142 -
143 -{{noformat}}
144 -
145 -ERXLanguages = (en,jp,fr_ca)
146 -
147 -{{/noformat}}
148 -
149 -Then, for the attribute you'd like to localize, add the ERXLanguages key to the UserInfo for that specific attribute:
150 -
151 -[[image:ERXLocalizedUserInfo.png]]
152 -
153 153  ===== Direct Actions =====
154 154  
155 155  If you are defaulting to direct actions, you may not have a session. If you do not have a session, the server will return the default language specified in the Properties mentioned above. If you're using direct actions and you don't like that behavior, you can stick this in your direct action class: