function views_rss_handler_field_user_mail::options_form in Views RSS 6.2
Same name and namespace in other branches
- 7.2 views/views_rss_handler_field_user_mail.inc \views_rss_handler_field_user_mail::options_form()
File
- views/
views_rss_handler_field_user_mail.inc, line 16 - Field handler to provide additional control for the email field.
Class
- views_rss_handler_field_user_mail
- @file Field handler to provide additional control for the email field.
Code
function options_form(&$form, &$form_state) {
parent::options_form($form, $form_state);
$form['rss_format'] = array(
'#title' => t('Display type'),
'#type' => 'select',
'#options' => array(
'default' => t('Generic email'),
'with_name' => t('RSS <author> element (with user name)'),
),
'#default_value' => isset($this->options['rss_format']) ? $this->options['rss_format'] : 'default',
'#weight' => 1,
);
// Move "Link this field" radios below just added "Display type",
// to be hidden when "RSS <author> element" is selected.
$form['link_to_user']['#weight'] = 2;
$form['link_to_user']['#process'] = array(
'expand_radios',
'views_process_dependency',
);
$form['link_to_user']['#dependency'] = array(
'edit-options-rss-format' => array(
'default',
),
);
$form['link_to_user']['#prefix'] = '<div id="edit-options-link-to-user-wrapper" style="padding-left:0">';
$form['link_to_user']['#suffix'] = '</div>';
}