1 ********************************************************************
2 D R U P A L M O D U L E
3 ********************************************************************
4 Name: i18n module and translation module
6 Email: drupal at reyero dot net
8 ********************************************************************
9 This is the 5.x version of i18n module, and works with Drupal 5.x
10 ********************************************************************
12 ********************************************************************
13 Updated documentation will be kept on-line at http://drupal.org/node/67817
14 ********************************************************************
19 1. Create folder 'sites/all/modules/i18n' and copy all the modules files, keeping directory structure, to this folder.
20 2. If updating, run the update.php script following the standard procedure for Drupal updates.
22 POST-INSTALLATION/CONFIGURATION:
24 - Enable the module/s in: Administer > Site building > modules
25 These modules are grouped under 'Multilanguage - i18n' package
26 Recommeded default is to enable: Internationalization, Translation
27 * Other modules are for very specific features.
29 - Configure the modules in
30 Administer > Site Configuration > Multilingual system
32 You might get an error message about languages not being enabled yet.
33 Visit the suggested page (Manage Languages) and enable the languages you need.
34 In case you find out they're already enabled, just press the button "save configuration".
36 - Enable multilingual support for each content type you want to translate
37 administer > content management > content types > edit (for each type separately)
39 A new field 'language' and a new tab 'translations' will be available when editing these node types
41 - There are now two language blocks
42 - A simple language switcher provided by i18n.module
43 - A translation block provided by translation.module
45 - Set up language for existing nodes, editing them manually.
46 - Set up language for existing taxonomy terms
47 Only terms in the node's language or terms without language will show up when editing a node
49 Language Definition [NEW for Drupal 5]
51 RECOMMENDED: You can use the languages defined -and enabled- in 'locale' module
53 ADVANCED, EXPERTS ONLY:
54 Modify the Drupal configuration file '../settings.php' to define the languages you want to use.
55 For instance, for English, Spanish:
57 $conf['i18n_languages'] = array(
58 'site_default' => 'en', // Default language
59 'name' => array('es' => "Spanish", 'en' => 'English'), // English names for languages
60 'native' => array('es' => "Español", 'en' => 'English'), // Native names
61 'enabled' => array('es' => TRUE, 'en' => TRUE), // Languages enabled
62 // 'rtl' => array('es' => TRUE), // This only if Spanish were an RTL language, which is not
65 * This will override languages defined by locale module
67 Language dependent variables
68 ============================
69 The list of variables to be made language dependent must be defined in the config file:
73 $conf['i18n_variables'] = array(
84 'user_registration_help',
85 'user_mail_welcome_subject',
86 'user_mail_welcome_body',
87 'user_mail_approval_subject',
88 'user_mail_approval_body',
89 'user_mail_pass_subject',
90 'user_mail_pass_body',
91 // Primary and secondary links
93 'menu_secondary_menu';
94 // Theme settings. This is an 'all or nothing' for each theme
95 // This is for 'garland' theme, for other theme it would be 'theme_[themename]_settings'
96 'theme_garland_settings',
100 These are only some suggested ones, but you can add as many Drupal variables as you want to the array.
102 You need to redefine these variables for the first time for every language, as previous values are lost and they return to defaults -they will be back if you disable i18n-.
104 Language dependent tables
105 =========================
106 [ADVANCED, NOT REQUIRED, HANDLE WITH CARE, MAY BREAK YOUR SITE, just for experimentation and *really advanced* use]
107 This module can manage language dependent tables, which means you can have different specific tables for each language, and the one for the current language will be selected at run time.
109 You need to modify $db_prefix and add a new global variable $db_prefix_i18n in .conf file. This is a sample:
113 'default' => 'prefix_', // The default prefix
117 [IMPORTANT UPDATE: The way to add a new global variable, since Drupal 4.7 is through the $GLOBALS array]
119 $GLOBALS['db_prefix_i18n'] = array (
120 // '**' will be replaced by language code at runtime.
121 'table1' => 'prefix_**_'
122 'table2' => 'prefix_**_',
128 For support, please create a support request for this module's project: http://drupal.org/project/i18n
130 If you need professional support, contact me by e-mail: freelance at reyero dot net
133 ====================================================================
134 Jose A. Reyero, freelance at reyero dot net, http://www.reyero.net
136 Feedback is welcomed.