public function FeedsTermProcessor::configForm in Feeds 7
Same name and namespace in other branches
- 6 plugins/FeedsTermProcessor.inc \FeedsTermProcessor::configForm()
Override parent::configForm().
Overrides FeedsConfigurable::configForm
File
- plugins/
FeedsTermProcessor.inc, line 147 - FeedsTermProcessor class.
Class
- FeedsTermProcessor
- Feeds processor plugin. Create taxonomy terms from feed items.
Code
public function configForm(&$form_state) {
$options = array(
0 => t('Select a vocabulary'),
);
foreach (taxonomy_get_vocabularies() as $vocab) {
$options[$vocab->machine_name] = check_plain($vocab->name);
}
$form = array();
$form['vocabulary'] = array(
'#type' => 'select',
'#title' => t('Import to vocabulary'),
'#description' => t('Choose the vocabulary to import into. <strong>CAUTION:</strong> when deleting terms through the "Delete items" tab, Feeds will delete <em>all</em> terms from this vocabulary.'),
'#options' => $options,
'#default_value' => $this->config['vocabulary'],
);
$form['update_existing'] = array(
'#type' => 'radios',
'#title' => t('Update existing terms'),
'#description' => t('Select how existing terms should be updated. Existing terms will be determined using mappings that are a "unique target".'),
'#options' => array(
FEEDS_SKIP_EXISTING => 'Do not update existing terms',
FEEDS_REPLACE_EXISTING => 'Replace existing terms',
FEEDS_UPDATE_EXISTING => 'Update existing terms (slower than replacing them)',
),
'#default_value' => $this->config['update_existing'],
);
return $form;
}