You are here

function views_handler_field_node_link::options_form in Views (for Drupal 7) 6.3

Same name and namespace in other branches
  1. 6.2 modules/node/views_handler_field_node_link.inc \views_handler_field_node_link::options_form()
  2. 7.3 modules/node/views_handler_field_node_link.inc \views_handler_field_node_link::options_form()

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

Overrides views_handler_field::options_form

File

modules/node/views_handler_field_node_link.inc, line 21

Class

views_handler_field_node_link
Field handler to present a link to the node.

Code

function options_form(&$form, &$form_state) {
  parent::options_form($form, $form_state);
  $form['text'] = array(
    '#type' => 'textfield',
    '#title' => t('Text to display'),
    '#default_value' => $this->options['text'],
  );

  // The path is set by render_link function so don't allow to set it.
  $form['alter']['path'] = array(
    '#access' => FALSE,
  );
  $form['alter']['external'] = array(
    '#access' => FALSE,
  );
}