function title_field_term_description_submit in Title 7
Submit callback for the taxonomy term description.
1 string reference to 'title_field_term_description_submit'
- title_entity_info in ./
title.core.inc - Implements hook_entity_info().
File
- ./
title.core.inc, line 114 - Provide field replacement information.
Code
function title_field_term_description_submit($entity_type, $entity, $legacy_field, $info, $langcode, &$values) {
if (!isset($values['description'])) {
$values['description'] = array();
}
foreach (array(
'value',
'format',
) as $key) {
if (isset($entity->{$info['field']['field_name']}[$langcode][0][$key])) {
$values['description'][$key] = $entity->{$info['field']['field_name']}[$langcode][0][$key];
}
else {
$values['description'][$key] = $key == 'value' ? '' : filter_default_format();
}
}
}