function synonyms_features_export_options in Synonyms 7
Implements hook_features_export_options().
File
- ./
synonyms.features.inc, line 41 - Synonyms module integration with Features.
Code
function synonyms_features_export_options() {
$options = array();
foreach (synonyms_behavior_get_all_enabled() as $behavior_implementation) {
$key = array(
$behavior_implementation['entity_type'],
$behavior_implementation['bundle'],
$behavior_implementation['provider'],
$behavior_implementation['behavior'],
);
if ($behavior_implementation['entity_type'] == $behavior_implementation['bundle']) {
$label = t('@entity_type @provider @behavior', array(
'@entity_type' => $behavior_implementation['entity_type'],
'@provider' => $behavior_implementation['label'],
'@behavior' => $behavior_implementation['behavior'],
));
}
else {
$label = t('@entity_type @bundle @provider @behavior', array(
'@entity_type' => $behavior_implementation['entity_type'],
'@bundle' => $behavior_implementation['bundle'],
'@provider' => $behavior_implementation['label'],
'@behavior' => $behavior_implementation['behavior'],
));
}
$options[implode(':', $key)] = $label;
}
return $options;
}