function drupagram_views_handler_field_caption::options_form in Drupagram 7
Default options form provides the label widget that all fields should have.
Overrides views_handler_field::options_form
File
- ./
drupagram_views_field_handlers.inc, line 93 - Drupagram views field handlers.
Class
- drupagram_views_handler_field_caption
- Field handler to provide simple renderer that turns a URL into a clickable link.
Code
function options_form(&$form, &$form_state) {
parent::options_form($form, $form_state);
$form['format'] = array(
'#type' => 'select',
'#title' => t('Display format'),
'#description' => t('How should the serialized data be displayed. You can choose a custom array/object key or a print_r on the full output.'),
'#options' => array(
'unserialized' => t('Full data'),
'key' => t('A certain key'),
),
'#default_value' => $this->options['format'],
);
$form['key'] = array(
'#type' => 'select',
'#title' => t('Which key should be displayed'),
'#options' => array(
'text' => t('Caption text'),
'created_time' => t('Created time'),
'from' => t('Caption author information'),
'id' => t('ID'),
),
'#default_value' => $this->options['key'],
'#dependency' => array(
'edit-options-format' => array(
'key',
),
),
);
}