You are here

function hook_feeds_parser_sources_alter in Feeds 7

Same name and namespace in other branches
  1. 8.2 feeds.api.php \hook_feeds_parser_sources_alter()
  2. 6 feeds.api.php \hook_feeds_parser_sources_alter()
  3. 7.2 feeds.api.php \hook_feeds_parser_sources_alter()

Alter mapping sources.

Use this hook to add additional mapping sources for any parser. Allows for registering a callback to be invoked at mapping time.

my_callback(FeedsImportBatch $batch, $key)

See also

my_source_get_source().

locale_feeds_parser_sources_alter().

Related topics

3 functions implement hook_feeds_parser_sources_alter()

Note: this list is generated by pattern matching, so it may include some functions that are not actually implementations of this hook.

locale_feeds_parser_sources_alter in mappers/locale.inc
Implements hook_feeds_parser_sources_alter().
og_feeds_parser_sources_alter in mappers/og.inc
Implements hook_feeds_parser_sources_alter().
taxonomy_feeds_parser_sources_alter in mappers/taxonomy.inc
Implements hook_feeds_parser_sources_alter().

File

./feeds.api.php, line 144

Code

function hook_feeds_parser_sources_alter(&$sources, $content_type) {
  $sources['my_source'] = array(
    'name' => t('Images in description element'),
    'description' => t('Images occuring in the description element of a feed item.'),
    'callback' => 'my_source_get_source',
  );
}