You are here

function isbn_feeds_processor_targets in ISBN Field 7

Implements hook_feeds_processor_targets().

File

./isbn.feeds.inc, line 11
Provides integration with Feeds module (http://drupal.org/project/feeds).

Code

function isbn_feeds_processor_targets($entity_type, $bundle) {
  $targets = array();
  foreach (field_info_instances($entity_type, $bundle) as $name => $instance) {
    $info = field_info_field($name);
    if ($info['type'] == 'isbn') {
      $targets[$name] = array(
        'name' => check_plain($instance['label']),
        'callback' => 'isbn_feeds_set_target',
        'description' => t('The @label field of the node.', array(
          '@label' => $instance['label'],
        )),
      );
    }
  }
  return $targets;
}