function i18n_admin_settings in Internationalization 6
Same name and namespace in other branches
- 5.3 i18n.module \i18n_admin_settings()
- 5 i18n.module \i18n_admin_settings()
- 5.2 i18n.module \i18n_admin_settings()
Form builder function.
TO DO: Add exclude paths for content selection Some options have been removed from previous versions:
- Languages are now taken from locale module unless defined in settings file.
- Language dependent tables are authomatically used if defined in settings file.
1 string reference to 'i18n_admin_settings'
- i18n_menu in ./
i18n.module - Implementation of hook_menu().
File
- ./
i18n.admin.inc, line 16 - Extended multilanguage administration and module settings UI.
Code
function i18n_admin_settings() {
// Content selection options.
$form['selection'] = array(
'#type' => 'fieldset',
'#title' => t('Content selection'),
);
$form['selection']['i18n_selection_mode'] = array(
'#type' => 'radios',
'#title' => t('Content selection mode'),
'#default_value' => variable_get('i18n_selection_mode', 'simple'),
'#options' => _i18n_selection_mode(),
'#description' => t('Determines which content to show depending on the current page language and the default language of the site.'),
);
// Node translation links setting.
$form['links'] = array(
'#type' => 'fieldset',
'#title' => t('Content translation links'),
);
$form['links']['i18n_hide_translation_links'] = array(
'#type' => 'checkbox',
'#title' => t('Hide content translation links'),
'#description' => t('Hide the links to translations in content body and teasers. If you choose this option, switching language will only be available from the language switcher block.'),
'#default_value' => variable_get('i18n_hide_translation_links', 0),
);
$form['links']['i18n_translation_switch'] = array(
'#type' => 'checkbox',
'#title' => t('Switch interface for translating'),
'#default_value' => variable_get('i18n_translation_switch', 0),
'#description' => t('Switch interface language to fit node language when creating or editing a translation. If not checked the interface language will be independent from node language.'),
);
return system_settings_form($form);
}