function lingotek_translatable_node_fields in Lingotek Translation 7.4
Same name and namespace in other branches
- 7.2 lingotek.module \lingotek_translatable_node_fields()
- 7.3 lingotek.module \lingotek_translatable_node_fields()
Gets a list of fields with translation enabled.
Return value
array An array of the machine names for translatable fields in the system.
1 call to lingotek_translatable_node_fields()
- lingotek_field_language_data_cleanup_update_node in ./
lingotek.batch.inc - Ensures correct language-specific field data for the specified item.
File
- ./
lingotek.module, line 1431
Code
function lingotek_translatable_node_fields() {
$fields = field_info_fields();
$translatable_fields = array();
foreach ($fields as $field_id => $field) {
foreach ($field['bundles'] as $type => $instance) {
if (field_is_translatable($type, $field)) {
$translatable_fields[] = $field['field_name'];
}
}
}
return $translatable_fields;
}