Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Use a <a href="http://www.gwtproject.org/articles/dynamic_host_page.html" rel="nofollow noreferrer"><em>dynamic host page</em></a> where you inject the proper <code>&lt;meta name="gwt:property" content="locale=XXX"&gt;</code>.</p> <p>Remember the GWT <a href="https://developers.google.com/web-toolkit/doc/latest/DevGuideOrganizingProjects#DevGuideBootstrap" rel="nofollow noreferrer">bootstrap sequence</a>: once your <code>onModuleLoad</code> has been called, the choice of the permutation (which includes the locale) has already been made. You have to alter the bootstrap sequence so it chooses the <em>proper</em> permutation for the user. <code>?locale=XXX</code> does this (because the <code>locale</code> property has a <a href="https://developers.google.com/web-toolkit/doc/latest/DevGuideOrganizingProjects#DevGuideModuleXml" rel="nofollow noreferrer"><code>&lt;property-provider&gt;</code></a> that reads the <code>locale</code> query-string parameter, among other things), as well as the <code>&lt;meta&gt;</code> above.</p> <p>See also <a href="https://code.google.com/p/google-web-toolkit-incubator/wiki/ServerSideLocaleSelection" rel="nofollow noreferrer">https://code.google.com/p/google-web-toolkit-incubator/wiki/ServerSideLocaleSelection</a> for some idea (BEWARE: deprecated project!)</p> <p>Finally, there are a few issues with your <code>*.gwt.xml</code>, starting with <code>kh</code> not being a <a href="http://tools.ietf.org/html/bcp47" rel="nofollow noreferrer">valid locale</a>.</p> <p>The workflow for internationalizing your app is as follows:</p> <ol> <li><p>list your locales:</p> <pre><code>&lt;extend-property name="locale" value="en" /&gt; &lt;extend-property name="locale" value="fr" /&gt; </code></pre></li> <li><p>remove the <code>default</code> locale by setting the <code>locale</code> property to the full list of supported locales:</p> <pre><code>&lt;set-property name="locale" value="en,fr" /&gt; </code></pre></li> <li><p>set the fallback locale:</p> <pre><code>&lt;set-property-fallback name="locale" value="en" /&gt; </code></pre></li> </ol> <p>Optionally, you can select how the locale is determined using the properties <code>locale.queryparam</code>, <code>locale.cookie</code>, <code>locale.usemeta</code>, <code>locale.useragent</code>, and <code>locale.searchorder</code> (see the <code>I18N.gwt.xml</code> for their default and accepted values).</p> <p>And finally, add code to select the locale (e.g. the dynamic <code>&lt;meta&gt;</code> above)</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload