You are here

function views_db_object::get_item in Views (for Drupal 7) 6.3

Same name and namespace in other branches
  1. 6.2 includes/view.inc \views_db_object::get_item()
  2. 7.3 includes/view.inc \views_db_object::get_item()

Get the configuration of an item (field/sort/filter/etc) on a given display.

1 call to views_db_object::get_item()
views_db_object::set_item_option in includes/view.inc
Set an option on an item.

File

includes/view.inc, line 2309
view.inc Provides the view object type and associated methods.

Class

views_db_object
Base class for views' database objects.

Code

function get_item($display_id, $type, $id) {

  // Get info about the types so we can get the right data.
  $types = views_object_types();

  // Initialize the display
  $this
    ->set_display($display_id);

  // Get the existing configuration
  $fields = $this->display[$display_id]->handler
    ->get_option($types[$type]['plural']);
  return isset($fields[$id]) ? $fields[$id] : NULL;
}