Configure Hosts for Sites with Multiple Languages

This topic applies to

Applies to

SuiteCommerce Web Stores

The hosts array within the Configuration.js file provides language-specific and currency-specific site support for multiple languages and currencies. This functionality is disabled by default. To enable this feature, configure the host for each language and define specific properties.

Follow the correct configuration procedures below, depending on the version of SuiteCommerce you are implementing. For information on configurable properties, regardless of your implementation, see Hosts Subtab.

This topic applies to

Applies to

SuiteCommerce Web Stores | Aconcagua | Kilimanjaro | Elbrus | Vinson

Configure Hosts with the SuiteCommerce Configuration Record

To configure the hosts array:

  1. Select the domain to configure at Setup > SuiteCommerce Advanced > Configuration.

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

  3. Set feature properties as required.

  4. Save the Configuration record.

This topic applies to

Applies to

Mont Blanc | Denali

Configure the hosts Array

To configure the hosts array (pre-Vinson):

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

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

  3. Setup the SspLibraries module for customization.

    See Customize and Extend Core SuiteCommerce Advanced Modules for detailed information.

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

  5. Within the hosts array, define a unique host for each location using the title property.

  6. Define the currencies and languages arrays for each host using the properties defined in this section.

    Note

    For detailed information on the hosts array in a pre-Vinson implementation, see Hosts Array Parameters (pre-Vinson).


    For example, you want to set up a multiple-language site that contains three geographic locations: the United States, South America, and France. For each location, you want to define specific currencies and languages according to the following table:

    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 to allow multiple languages and enable the applicable languages and currencies. You then set up hosted domains for each translated language.

    The following code snippet shows what your customization might look like.

    ,   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.