Fog Creek Software
Fog Creek Software

CityDesk 2.0-Documentation
Creating a Multilingual Site

CityDesk includes features that help manage a site that appears in multiple languages:

One language in your site is considered primary. This is the language in which articles are originally written. CityDesk assumes that translators will translate each article from the primary language to the non-primary languages. By default, the primary language is English, although you can change this in the Languages Dialog by renaming "English" to something else.

When you are editing an article in the non-primary language, a Translated checkbox appears above the body of the article. You can use this checkbox to keep track of which articles have been translated to which languages.

For example, if your site has English as the primary language and also French and German, here's how you work with CityDesk:

The primary language does not have a "translated" checkbox.

To define the list of languages in which your site appears:

*  Use the Languages Dialog to edit the list of languages:

Languages
Languages

To translate articles:

*  Search for untranslated articles.

*  Open the articles that you wish to translate.

*  Use the View » Second Language to switch the article editor into split-screen mode. This allows you to see two languages side-by-side.

Note: You can show any two languages side-by-side using View » First Language and View » Second Language. To go back to single-language mode, choose View » Second Language » None.

*  Write the translation.

*  Click on the Translated checkbox in the upper right hand corner (above the article body) so that CityDesk knows that this article is translated. This prevents it from showing up in future searches for untranslated articles.

Normally, when you publish a site with multiple languages, CityDesk creates one subdirectory for each language and publishes the entire site, in the appropriate language, in each subdirectory. You may wish to publish the different language versions of your site on different web servers or in different locations on the same web server. To do this:

*  Create a Publish Location for each version, specifying the language you wish to publish in the wizard.

CityDesk only maintains separate copies of articles for each language. Other files, such as HTML files or GIF files, are universal and will be published no matter what language you are publishing. If these files contain text which needs to be translated, you will need to provide your own alternate copies of the files. You might use a naming convention, for example, banner-eng.gif and banner-spa.gif.

If your templates contain any text which needs to be translated:

*  Create a separate template family for each language.

*  Create a Publish Location for each version, specifying the language you wish to publish and the appropriate template family in the wizard.

Alternately, you can use a single template for all global versions of your site, as long as you make sure that the template itself does not contain any text. Here is a system for doing that:

You can automatically create a link from each article to the translated version of that article by using the .abslink variable in your templates. For example, in a bilingual French/English site, the English version of each article can have a link to the French version, and vice versa. Here's how to accomplish that:

Suppose you have a site with two languages (English, French) and two Template Families (EnglishHTML, FrenchHTML). There is one template called Simple.  You have two publish locations: http://mysite.com for English and http://monsite.fr for French.

*  In the EnglishHTML Simple template, add a link like this:

<a href="http://monsite.fr/{$.abslink$}">Edition Française</a>

*  In the FrenchHTML Simple template, add a link like this:

<a href="http://mysite.com/{$.abslink$}">English Version</a>

Notice the use of .abslink which returns a link to the article that includes the full folder path. For example for an article in the news/articles/today folder named MyItem, .abslink would return news/articles/today/MyItem.html.

CityDesk Documentation -  Home


©Copyright 2001-2003 Fog Creek Software, Inc. All Rights Reserved.