function views_handler_field::option_definition in Views (for Drupal 7) 6.2
Same name and namespace in other branches
- 6.3 handlers/views_handler_field.inc \views_handler_field::option_definition()
- 7.3 handlers/views_handler_field.inc \views_handler_field::option_definition()
Information about options for all kinds of purposes will be held here.
'option_name' => array(
- 'default' => default value,
- 'translatable' => TRUE/FALSE (wrap in t() on export if true),
- 'contains' => array of items this contains, with its own defaults, etc.
If contains is set, the default will be ignored and assumed to
be array()
),
Each option may have any of the following functions:
- export_option_OPTIONNAME -- Special export handling if necessary.
- translate_option_OPTIONNAME -- Special handling for translating data within the option, if necessary.
Overrides views_object::option_definition
26 calls to views_handler_field::option_definition()
- views_handler_field_accesslog_path::option_definition in modules/
statistics/ views_handler_field_accesslog_path.inc - Information about options for all kinds of purposes will be held here.
- views_handler_field_aggregator_category::option_definition in modules/
aggregator/ views_handler_field_aggregator_category.inc - Information about options for all kinds of purposes will be held here.
- views_handler_field_aggregator_title_link::option_definition in modules/
aggregator/ views_handler_field_aggregator_title_link.inc - Information about options for all kinds of purposes will be held here.
- views_handler_field_boolean::option_definition in handlers/
views_handler_field_boolean.inc - Information about options for all kinds of purposes will be held here.
- views_handler_field_comment::option_definition in modules/
comment/ views_handler_field_comment.inc - Information about options for all kinds of purposes will be held here.
26 methods override views_handler_field::option_definition()
- views_handler_field_accesslog_path::option_definition in modules/
statistics/ views_handler_field_accesslog_path.inc - Information about options for all kinds of purposes will be held here.
- views_handler_field_aggregator_category::option_definition in modules/
aggregator/ views_handler_field_aggregator_category.inc - Information about options for all kinds of purposes will be held here.
- views_handler_field_aggregator_title_link::option_definition in modules/
aggregator/ views_handler_field_aggregator_title_link.inc - Information about options for all kinds of purposes will be held here.
- views_handler_field_boolean::option_definition in handlers/
views_handler_field_boolean.inc - Information about options for all kinds of purposes will be held here.
- views_handler_field_comment::option_definition in modules/
comment/ views_handler_field_comment.inc - Information about options for all kinds of purposes will be held here.
File
- handlers/
views_handler_field.inc, line 145
Class
- views_handler_field
- Base field handler that has no options and renders an unformatted field.
Code
function option_definition() {
$options = parent::option_definition();
$options['label'] = array(
'default' => $this->definition['title'],
'translatable' => TRUE,
);
$options['alter'] = array(
'contains' => array(
'alter_text' => array(
'default' => FALSE,
),
'text' => array(
'default' => '',
'translatable' => TRUE,
),
'make_link' => array(
'default' => FALSE,
),
'path' => array(
'default' => '',
'translatable' => TRUE,
),
'absolute' => array(
'default' => '',
'translatable' => FALSE,
),
'alt' => array(
'default' => '',
'translatable' => TRUE,
),
'rel' => array(
'default' => '',
),
'link_class' => array(
'default' => '',
),
'prefix' => array(
'default' => '',
'translatable' => TRUE,
),
'suffix' => array(
'default' => '',
'translatable' => TRUE,
),
'target' => array(
'default' => '',
'translatable' => TRUE,
),
'trim' => array(
'default' => FALSE,
),
'max_length' => array(
'default' => '',
),
'word_boundary' => array(
'default' => TRUE,
),
'ellipsis' => array(
'default' => TRUE,
),
'strip_tags' => array(
'default' => FALSE,
),
'html' => array(
'default' => FALSE,
),
),
);
$options['empty'] = array(
'default' => '',
'translatable' => TRUE,
);
$options['hide_empty'] = array(
'default' => FALSE,
);
$options['empty_zero'] = array(
'default' => FALSE,
);
$options['hide_alter_empty'] = array(
'default' => TRUE,
);
return $options;
}