You are here

function _views_system_get_type in Views System 6.2

Same name and namespace in other branches
  1. 6.3 views_system.module \_views_system_get_type()
  2. 7.3 views_system.module \_views_system_get_type()

Helper function; retrieves list of item types.

1 string reference to '_views_system_get_type'
views_system_views_data in views/views_system.views.inc
Implementation of hook_views_data().

File

./views_system.module, line 43
This module extends the Views module and allows to create customized lists (pages, blocks) of modules, themes, and theme engines that are or have been installed in Drupal's file system.

Code

function _views_system_get_type() {
  static $type = array();
  if (!$type) {
    $result = db_query('SELECT DISTINCT(type) FROM {system} ORDER BY type');
    while ($record = db_fetch_object($result)) {
      $type[$record->type] = _views_system_get_type_name($record->type);
    }
  }
  return $type;
}