function defaultcontent_import_sort in Default Content 7.2
Same name and namespace in other branches
- 7 defaultcontent.module \defaultcontent_import_sort()
use to sort component
this ask all alter plugins for a import_sort callback
3 string references to 'defaultcontent_import_sort'
- content_features_revert in ./
defaultcontent.features.inc - Implements hook_features_revert().
- defaultcontent_cron in ./
defaultcontent.module - Implements hook_cron().
- defaultcontent_remove_default_content in ./
defaultcontent.module
File
- ./
defaultcontent.module, line 349 - Module file for the Default content module which allow export and import of default content in a Drupal site.
Code
function defaultcontent_import_sort($a, $b) {
$plugins = defaultcontent_get_alter_plugins();
$cmp = 0;
foreach ($plugins as $plugin) {
$cb = isset($plugin['import_sort callback']) ? $plugin['import_sort callback'] : $plugin['name'] . '_import_sort';
if (function_exists($cb)) {
$cmp = $cb($a, $b);
}
}
return $cmp;
}