You are here

public function views_handler_field_file_size::options_form in Views (for Drupal 7) 7.3

Same name and namespace in other branches
  1. 6.3 handlers/views_handler_field.inc \views_handler_field_file_size::options_form()
  2. 6.2 handlers/views_handler_field.inc \views_handler_field_file_size::options_form()

Default options form provides the label widget that all fields should have.

Overrides views_handler_field::options_form

File

handlers/views_handler_field.inc, line 1701
Definition of views_handler_field.

Class

views_handler_field_file_size
Render a numeric value as a size.

Code

public function options_form(&$form, &$form_state) {
  parent::options_form($form, $form_state);
  $form['file_size_display'] = array(
    '#title' => t('File size display'),
    '#type' => 'select',
    '#options' => array(
      'formatted' => t('Formatted (in KB or MB)'),
      'bytes' => t('Raw bytes'),
    ),
  );
}