2 Replies Latest reply on Feb 1, 2010 9:53 AM by mhollis55

    Setting up a multiple Language Site

    PHE Admin Level 2

      Now I know this is slightly off topic of Web design, so if it cannot be answered here, can you point me to the best place for it to be answered?

      I have a site up and running at www.powerhouse.com.  Our next step for the site is to have a Spanish version and other languages down the road.  Ideally I would like to only change the text.  I would like the pages to point to all the existing pictures and things like that.  I was thinking the best way would either be a subdomain (espanol.powerhouse.com) or just a different folder (www.powerhouse.com/espanol)

      What would be the best, most efficient way?


      Thanks guys!

        • 1. Re: Setting up a multiple Language Site
          Rob Hecker2-uhQIgt Level 2

          The way I have done this is in the past is by using a database driven site and providing a CMS for the translators to develop the alternate language versions. In such a system, you don't have the maintenance nightmare of managing complete subsites for each language, but simply provide the correct language from the database. With PHP, this requires using "sessions" so the system remembers the appropriate language as the visitor moves from page to page.


          In the above case, "pages" would carrry a core name plus an extension identifying the language: For example, homepage_en.php or homepage_sp.php as well as a session variable called language. The session variable then holds identifiers like _en, _sp, _ch, _fr. That makes it possible for someone to bookmark a page in the site and have it open with the right language later.


          If you only have English and Spanish, as you said will be your start, then the method you use may not be a big deal, but as you add languages, I think the subfolder method will quickly drive you bonkers.


          You may also want to start making sure that pages, databases and everything that touches the content are set to the UTF8 characterset, so down the road you don't end up with characterset issues.

          • 2. Re: Setting up a multiple Language Site
            mhollis55 Level 4

            I'd make a master template for all pages that included navigation, your top banner and your footer and then translate each page, doing a save as... You will need a translation of your inventory on your Products page. That's being generated from a database, presumably and so you would need to add fields that include the foreign language and have that page specify that the output will be in Spanish.


            Rather than try to do a second site with a different URL, I'd place Spanish in a folder called /es and build the entire website underneath that. While most Latin Americans have generally good feelings about each other, localizing a site in Mexico or Spain may tend to be off-putting to some and may suggest that you have a national presence in Mexico (.mx), but you're not an Argentine company(.ar).


            But eventually, if you can purchase and register powerhouse.xx where xx is the country you intend to do business in, you may find this a good way to do business in Latin America.