function i18n_object_info in Internationalization 7
Get translation information for objects
16 calls to i18n_object_info()
- i18n_get_object in ./
i18n.module - Get object wrapper by object key.
- i18n_object_key in ./
i18n.module - Get key value from object/array
- i18n_object_wrapper::get_info in ./
i18n_object.inc - Get object info
- i18n_page_menu_items in ./
i18n.pages.inc - Create menu items for translatable objecs
- i18n_string_group_object_types in i18n_string/
i18n_string.i18n.inc - Get object types for text group
4 string references to 'i18n_object_info'
- i18n_field_entity_property_callback in i18n_field/
i18n_field.module - Callback to translate entity property info for a fields.
- i18n_field_i18n_object_info_alter in i18n_field/
i18n_field.module - Implements hook_i18n_object_info_alter().
- i18n_modules_enabled in ./
i18n.module - Implements hook_modules_enabled().
- i18n_page_menu_items in ./
i18n.pages.inc - Create menu items for translatable objecs
File
- ./
i18n.module, line 436 - Internationalization (i18n) module.
Code
function i18n_object_info($type = NULL, $property = NULL, $default = NULL) {
$info =& drupal_static(__FUNCTION__);
if (!$info) {
$info = module_invoke_all('i18n_object_info');
drupal_alter('i18n_object_info', $info);
}
if ($property) {
return isset($info[$type][$property]) ? $info[$type][$property] : $default;
}
elseif ($type) {
return isset($info[$type]) ? $info[$type] : array();
}
else {
return $info;
}
}