Multiple Languages

How to use multiple languages in your Imagevue gallery

Using Multiple Languages

With Imagevue, you can present your gallery in multiple languages if required. The Imagevue user interface is already provided in multiple languages, but you need to use language-tags if you also wish to have your titles, descriptions, text-pages and links accessible in multiple languages.

View Demo

In the following examples, the same gallery folder is displayed in multiple languages:
EnglishItalianoEspañolFrançaiseDeutschPусский中文

The gallery language is generally set by adding the language parameter:
?language=english

For example:
imagevuex.com/demo/x2/?language=english
imagevuex.com/demo/x2/?language=spanish

Interface Language

By default, Imagevue already provides dozens of languages ready to use for the gallery interface. You can set your default language by going to your Admin › settings › settings.language. Although this sets the language for your gallery interface, it will not affect your titles or descriptions until you effectively create them in multiple languages. You can edit languages by going to Admin › Languages

Item Language

You can set multiple languages for titles, descriptions, text-pages and menu-links by using language tags. Language tags are generally used by including your choice of languages inside language [tags]. In the example below, we have created a title for English and Spanish:

[english]This is a title[/english][spanish]Este es un título[/spanish]

The resulting output for English (?language=english) would be:

This is a title

Whereas the resulting output for Spanish (?language=spanish) would be:

Este es un título

You can also include text outside of the tags, which will display for any language. For example:

1. [english]This is a title[/english][spanish]Este es un título[/spanish] link

The resulting output for English (?language=english) would be:

1. This is a title link

Whereas the resulting output for Spanish (?language=spanish) would be:

2. Este es un título link

The benefits of adding items outside of the language tags, are for example links, menu-icons or images (in text-pages) which are global to all your languages.

Although you are using multiple languages, you only need to set [language] tags for items where you strictly need separate languages. For items that don’t have language tags, Imagevue will simply display the plain item text. Additionally, if a language is being viewed that a language tag is not created for, Imagevue will use the text from the first language tag.

How to Implement Languages for your Visitors

Now that you know how to set up your gallery to support multiple languages, you may wish to know how you can provide the language options for your visitors. There are several alternative implementations, depending slightly on your requirements. Most galleries don’t even need multiple languages, but there are some cases where you may want to present your portfolio for example in English, and then also in your native language ›

1. Links

The easiest way to provide your audience with a specific language, is simply by appending the ?language parameter in the URL of your gallery. For example if you want to provide a link to your Spanish version, the link would be:

{your-gallery-link}/?language=spanish

In our demo gallery:
/demo/x2/?language=spanish

* Keep in mind, you do not need to set the ?language parameter for your default language

2. Startpage Links

A simply way to provide a language option for your visitors, is to set up links on your start-page. In your start-page, simply add links in your title or description which link to your required languages. For example:

<a href="?language=english">English</a> | <a href="?language=spanish">Español</a>

3. Menu Links

Perhaps the best option for your visitors to switch between languages, is to provide language links in your Imagevue main menu. You can for example create a menu item that displays a link to the Spanish version from the English version, and a link to the English version from the Spanish version.

  • 1. Go to your Imagevue Admin › Manage, and click [+ New] on the top to create a new folder item
  • 2. Set the new folder to Use as:[Link] in the dropdown selector.
  • 3. In the title field, add your titles in the languages you require. For example
    [english]Spanish version[/english][spanish]English version[/spanish]
  • 4. The Description field is optional, but in the Link field, add your links for the languages:
    [english]?language=spanish[/english][spanish]?language=english[/spanish]

Now you have a gallery that displays a link to the “other” language than the one that is currently being viewed! Keep in mind, if you require additional languages, you may need to create separate menu links. Additionally, you may want to add country flag menu-icons for this link in your menu. You can download country flags png icons here or here.

4. Splash Page

If it is very important for your visitors to be able to select their language before the gallery loads, then you can create a basic splash page. The splash page will appear before the gallery, and provide language selection options for your visitors.

View ExampleDownload Source

  • To create your own splash page or edit the html example from above, you need to have some experience with Html (or someone must be able to help you).
  • Simply upload the file index.html into your gallery folder, and it will display before index.php which contains your actual gallery.
  • You can download additional Flag icon images here.
  • You will need to edit the file appropriately and include links to your languages as specified earlier. Feel free to edit the document as you like – You may like to add some text, logo, more languages and links.

5. Advanced Domain forwarding

If you have multiple domains or the same domain in two (or more) country codes, then you can use this to trigger different languages for each domain. For example, you may have a *.com domain for English and another *.[country] domain for your native language.

Simply open the file in your gallery root called htaccess.txt:

# RewriteEngine on

# RewriteCond %{SERVER_NAME} site\.de$ [NC]
# RewriteCond %{REQUEST_URI} ^/$ [NC]
# RewriteRule .* ?language=german [QSA]

# RewriteCond %{SERVER_NAME} site\.com$ [NC]
# RewriteCond %{REQUEST_URI} ^/$ [NC]
# RewriteRule .* ?language=english [QSA]

In the example above, the gallery will set ?language=german if the domain ends with *.de (German), and ?language=english if the domain ends with *.com. After you have edited the file to suit your domains and language, rename it to “.htaccess” and upload it to the root of your gallery

Notes

  • If you require visual differences for each language, you can also use separate themes for each of your languages. In the examples below, we have set separate themes for each language through the URL:
    {yourgallery}/?language=spanish&theme=spanish
    {yourgallery}/?language=english&theme=english

    Naturally, you will need to create themes for your languages first.

  • You could also use a more elaborate setup by creating separate language files spanish.html, english.html and so on for the languages you require. The benefit would be that the language parameter and theme parameter can be embedded directly into the code, so they don’t “pollute” your URL. This is generally done by duplicating the html for your gallery into multiple language files, and simply changing a few parameters in each document.
  • Important! Imagevue languages use browser cookies – This means that once your visitor clicks a specific language for viewing, their browser will stick to this language even when the ?language parameter is not set. The language will only reset- or change if they actually click a link where the ?language parameter is set.

13 Responses to "Using Multiple Languages"

  1. I am glad that it can display Chinese. But how to change the font type of a language?

  2. Hi

    I’ve tested the index.html file, but unfortunately it does not work as expected: it does not display before index.php.
    Do you know why?

    It is important for me, because in my site I’ve disabled the HTML version for the moment, and I’d like to show to user the information that my site is available only in Flash.

    Thx for any your suggesion you can give me..
    vincenzo

    • Do you have a link? Normally on normal server settings, “index.html” is set to display before any “index.html” files … If this is not the case, then either your server is configured differently, or you did not place the file in the correct location, or with incorrect name.

  3. Hi

    I’ve moved the index.html file into the root, and now it works!!

    But now I’ve an issue:
    I cannot change language from default lang.
    Not manually from address bar, adding ?language=xxx nor from the link included into the menu.

    Can you support me, once more?
    Thx
    Vincenzo

    • Yes of course … The problem now though, is that since you are using custom index file, it does not accept url variables like ?language. Unfortunately, there are some features in the default index.php that simply are lost if you need to use your own custom index.html … So the question is: Why do you need to use your own custom index.html?

  4. Hi
    first thing: thx a lot for your support.
    Second: my site is only flash based and not html. Therefore I need to have a check before gallery is up that explain the user to install flash if browser does not have it.

    Therefore I’ve renominated your index_template,html file in order to use it.
    But now is there any other alternative in order to show the messages to use flash w/o index.html?
    Thx again
    Vincenzo

    • Yes. I assume you have something resembling the src from our index.php in your html? You can hardcode the language directly into the code. For example:

      flashVars.language = ‘english’;

      Add that in the section where flashvars are defined. You can for example create an index html file for each of your languages, and hardcode the language into each document. For example:

      french.html
      english.html
      spanish.html

      In each document, you define the language from flashvars.

  5. Perfect mjau-mjau!

    We´re up and running with http://en.ekaele.com and http://www.ekaele.com

    Easy and great as usual!

  6. thx mjau-mjau

    I’ll study your suggestions…
    vincenzo

  7. Hello,
    I am not able to display anything (text, image, etc..) outside the [language][/language].
    Whatever the language and the stuff I want to display outside the tags, it’s not appearing on the text page.
    Is there something specific to do ?

    • Are you using the latest version of Imagevue? Do you have a link to your textpage so we can take a look? Easy way to fix this, would be to simply include everything you want in each [language] tag …

  8. lithuanian language available?


Comments