Configure Hosts for Sites with Multiple Languages

The hosts array in the Configuration.js file provides language-specific and currency-specific site support for multiple languages and currencies. This functionality is off by default, so you need to configure the host for each language and set specific properties to turn it on.

Follow the instructions below based on your implementation. For information on configurable properties, regardless of your implementation, see Hosts Subtab.

Configure Hosts with the SuiteCommerce Configuration Record

This procedure applies to SuiteCommerce and the Vinson release of SCA or later.

To configure the hosts array:

  1. Select the domain to configure at Commerce > Websites > Configuration.

  2. In the SuiteCommerce Configuration record, go to the Multi-Domain tab and the Hosts subtab.

  3. Set feature properties as required.

  4. Save the Configuration record.

Configure the hosts Array

This procedure applies to the Mont Blanc and Denali releases of SCA.

To configure the hosts array:

  1. Follow the steps presented in Set Up NetSuite for Localized Content.

  2. Set up a hosted domain for each language on your site. See Domains for details on how to create new hosted domains.

  3. Set up the SspLibraries module for customization.

    See Develop Your SCA Customization for detailed information.

  4. Open the Configuration.js file in the newly created module.

  5. In the hosts array, define a unique host for each location with the title property.

  6. For each host, define the currencies and languages arrays using the properties in this section.

    Note:

    For detailed information on the hosts array for Mont Blanc and Denali implementations, see Hosts Array Parameters (pre-Vinson).

    For example, say you want to set up a multi-language site with three locations: the United States, South America, and France. For each, you could define specific currencies and languages as shown in the table below:

    Location

    Currencies

    Languages

    United States

    U.S. Dollar

    English

    South America

    U.S. Dollar

    Argentinian Peso

    Uruguayan Peso

    Spanish

    Portuguese

    English

    France

    Euro

    U.S. Dollar

    French

    You set up NetSuite for multiple languages and enable the right languages and currencies, then create hosted domains for each translated language. The locale string must specify the country code and culture code for each language, using ISO standards (ISO 639 and ISO 3166 respectively). For example: en_US or es_ES.

    Here's an example of how your customization might look:

                         ,   hosts: [
             {
                title:'United States'
             ,   currencies:[
                   {
                      title:'American Dollars'
                   ,   code:'USD'
                   }
                ]
             ,   languages:[
                   {
                      title:'English'
                   ,   host:'en.mysite.com'
                   ,   locale:'en_US'
                   }
                ]
             }
             ,   {
                title:'South America'
             ,   currencies:[
                   {
                      title:'American Dollars'
                   ,   code:'USD'
                   }
                ,   {
                      title:'Peso Argentino'
                   ,   code:'ARS'
                   }
                ,   {
                      title:'Peso Uruguayo'
                   ,   code:'UYU'
                   }
                ]
             ,   languages:[
                   {
                      title:'Spanish'
                   ,   host:'sa.mysite.dev'
                   ,   locale:'es_ES'
                   }   
                ,   {
                      title:'Portuguese'
                   ,   host:'pt.sa.mysite.dev'
                   ,   locale:'pt_BR'
                   }
                ,   {
                      title:'English'
                   ,   host:'en.sa.mysite.dev'
                   ,   locale:'en'
                   }
                ]
             },
             {
                title:'French'
             ,   currencies:[
                   {
                      title:'Euro'
                   ,   code:'EUR'
                   }
                ,   {
                      title:'American Dolars'
                   ,   code:'USD'
                   }
                ]
             ,   languages:[
                   {
                      title:'French'
                   ,   host:'fr.mysite.com'
                   ,   locale:'fr_FR'
                   }
                ]
             }
          ] 
    
                    
  7. Deploy the module to your site.

Related Topics

General Notices