Setting up the Site as Multilingual
To set up a multilingual website, before starting the translations you have to perform several steps that are described below:
Step 1. Create or update mandatory items in language *.
Access to the page to create the mandatory items in language '*' is achieved by clicking on the 'Set the site as Multilingual' link in any of the KMFasTrans views. When you click on that link, the following page will be displayed
These items are necessary for the Joomla multi-language native mode and consists of the following:
- A default home menu assigned to language 'All'.
- This process creates a menu with title "Menu-All", menu type "defaultallmenu" and type "Category List".
- A root category assigned to language 'All', required for "Menu Item-All".
- This process creates a category with title "Root Category-All-Articles".
- A default home menu item assigned to language 'All' as the default Home page for language "All".
- This process creates a menu item with title "Menu Item-All" in the menu "Menu-All" .
- A menu-type module linked to menu "Menu-All" and unpublished.
- This process creates a menu-type module with title "Menu Module-All" in the position "default_all_menu_module_position" (a fictitious one) .
- A default home menu assigned to language 'All'.
Each time the Create button is pressed, KM FasTrans will try to create these four items and will create only those that do not exist yet. You will be informed of the items that already existed and those just created. You can also know at any moment the status of these items on this page and also in the Control Panel window.
If in any of the elements, instead of the OK state you see the text Not found or not properly configured!, then that element does not exist or is in the trash or archived. Pressing the Create button again will create the element or it will be published if it was archived or in the trash.
You don't have to use these items for anything ( and is better if you don't use them at all as if problems arise you could delete them and recreate pressing this button. An exception to this might be the category, which may be used freely if needed). If you need a menu, menu item and menu module assigned to language 'All' you can create as many as you need without changing anything of those four items that were created in this step.
If you already had these items in place before installing KMFasTrans, you can just ignore the warning messages, or you can click on the button anyway because it will not affect what you had previosly, the only change will be that the default home page for language 'All' will be the new automatically created menu item with title "Menu Item-All". You also can use the proper option in KMFasTrans configuration to disable the warning message.
Step 2. Change language of items from * to site default language.
Access to the page to change the language of items in language 'All' is achieved by clicking on the 'Set the site as Multilingual' link in any of the KMFasTrans views. When you click on that link, the following page will be displayed:
To change the language of the elements you want, from '*' to the site default language or to the language you choose you must do the following:
1. In the 'Change Language to' drop-down below, the site default language is pre-selected. If it is not correct, select the one that is.
2. In the 'Select Items' drop-down, select the mode you want. You have an explanation of what each mode does when hovering the mouse over the label.
3. The 'Select Components' drop-down is only visible if you selected 'All items' or 'All except those selected below' in the 'Select Items' drop-down. If it is visible you have to select the components for which you want the change to be applied. If you do not select any, no changes will be made.
4. Select, in the table of components below (if it is visible), the elements that you want to change or not to change depending on the mode you have selected. If you selected 'All items' in the 'Select Items' drop-down, the table will not be displayed and all the items of the components selected in 'Select Components' drop-down will be modified.
5. Finally click on the 'Change Language' button to change the language.
As with any major changes to the website, it is advisable that you make a backup before taking this action.
Step 3. Assign language to menus.
When installing the extension, KMFasTrans will add the language field as a required field for menus, so you can easily control the language of the menu-items assigned to a menu.
The installation process tries to assign the language to each menu based on the language of the menu items assigned to that menu. Sometimes it does not get it and assigns the Default Site Language.
In all cases it is necessary to perform a revision of the assigned language and in cases where the installation failed to assign the language there will be menus that have been assigned the Default Site Language incorrectly and the correct one must be assigned manually.
To do this, KMFasTrans has included a 'Batch' function on the page that lists all the menus to be able to change the language to several menus simultaneously.
You just have to select all the menus that must have a new language and click on the 'Batch' button to obtain the following window:
Select the appropriate language in 'Set Language' dropdown and click on 'Process' to make the change.
Step 4. Create Sets of Translations.
If in your Joomla installation there are elements that are translation of other elements before the installation of KMFasTrans, it is necessary to manually create some translation sets. KMFasTrans will create the translation sets from the Joomla associations found during installation, but it cannot create them for the elements for which Joomla associations are not supported.
Thus it is necessary to manually create translation sets for Menus, Banners, Modules, Fields Groups, Fields, Tags and Web links and third party extensions.
The most efficient way to do this is by using the Multiple Manual Associations functionality. In the Multiple Manual Associations online help of this page you have all the necessary information to perform this step.
Step 5. Publish the Language Filter plugin.
You have to publish the Language Filter plugin.
You can access the plugin from Extensions->Plugins and then search por the Language Filter. You will have the following screen:
You have several options. It is important that if you want to have translated content switching when switching languages you have to set the value 'YES' for the option "Associations". If you forget to do it at first then you will have to create associations manually re-editing the items.
Step 6. Publish the Language Switcher module.
KMFT Language Switcher module is an alternative to native Joomla Language Switcher module when the component KMFasTrans is installed. What this module adds respect to the native module is:
Language switching at the article level for categories in language 'All'.
Joomla 3.x provides article level switching, but if the language of your article and the category to wich the article belongs is 'All' then you still need the KMFT Language Switcher module. As an example, suppose we have a menu item whose type is Featured Articles in English, which shows the articles that belong to one or more categories. If one of these categories has language 'All' and there is an article in language 'All' assigned to that category, when the menu item is displayed, all the items in those categories will be seen, including the one in language 'All'. However, if we click on the title of the article to see it in its entirety, and then we switch to another language, for example Spanish, the native Joomla Switching Module will not show in Spanish the same article that is in language 'All', but the list of featured articles in Spanish.
Language switching at the article Table of Contents
If you have an article with a lot of text such as a user manual and you have divided it into sections using the 'Page Break' button in the editor, and you have enabled the 'Button - Page Break' and 'Content - Page Break' plugins, when the article id displayed a table of contents will be displayed. Clicking on a link in the table of contents will display the corresponding section. Well, if you use the KMFT Language Switcher, when you change the language you will see the same section in the new language.
Preserving custom parameters in the url in SEF mode
If you want to add custom parameters to your urls and you have SEF mode enabled, the KMFT Language Switcher module will keep those parameters when switching language. For example, if you have a menu item of the type https://mysite/myarticle and you want to add one or more parameters to have a url of the form https://mysite/myarticle?par1=value1&par2=value2 when switching language, all the links to any other language will have the string ?par1=value1&par2=value2 added to the end of the url, for example for the Spanish language we would have https://misitio/es/miarticulo/?par1=value1&par2=value2.
If you don't use any of the above features you can publish the standard Joomla! Language Switcher module.