function views_plugin_list

cis7 views.module views_plugin_list()
cle7 views.module views_plugin_list()
elmsmedia7 views.module views_plugin_list()
icor7 views.module views_plugin_list()
meedjum_blog7 views.module views_plugin_list()
mooc7 views.module views_plugin_list()

Returns a list of plugins and metadata about them.

Return value

array An array keyed by PLUGIN_TYPE:PLUGIN_NAME, like 'display:page' or 'pager:full', containing an array with the following keys:

  • title: The plugin's title.
  • type: The plugin type.
  • module: The module providing the plugin.
  • views: An array of enabled Views that are currently using this plugin, keyed by machine name.
2 calls to views_plugin_list()
views_features_pipe_views_view_alter in sites/all/modules/ulmus/features/includes/features.ctools.inc
Implements hook_features_pipe_COMPONENT_alter() for views_view.
views_ui_plugin_list in sites/all/modules/ulmus/views/includes/admin.inc
Lists all plugins and what enabled Views use them.
1 string reference to 'views_plugin_list'
views_features_pipe_views_view_alter in sites/all/modules/ulmus/features/includes/features.ctools.inc
Implements hook_features_pipe_COMPONENT_alter() for views_view.

File

sites/all/modules/ulmus/views/views.module, line 252
Primarily Drupal hooks and global API functions to manipulate views.

Code

function views_plugin_list() {
  $plugin_data = views_fetch_plugin_data();
  $plugins = array();
  foreach (views_get_enabled_views() as $view) {
    foreach ($view->display as $display_id => $display) {
      foreach ($plugin_data as $type => $info) {
        if ($type == 'display' && isset($display->display_plugin)) {
          $name = $display->display_plugin;
        }
        elseif (isset($display->display_options["{$type}_plugin"])) {
          $name = $display->display_options["{$type}_plugin"];
        }
        elseif (isset($display->display_options[$type]['type'])) {
          $name = $display->display_options[$type]['type'];
        }
        else {
          continue;
        }

        // Key first by the plugin type, then the name.
        $key = $type . ':' . $name;
        // Add info for this plugin.
        if (!isset($plugins[$key])) {
          $plugins[$key] = array(
            'type' => $type,
            'title' => check_plain($info[$name]['title']),
            'module' => check_plain($info[$name]['module']),
            'views' => array(),
          );
        }

        // Add this view to the list for this plugin.
        $plugins[$key]['views'][$view->name] = $view->name;
      }
    }
  }
  return $plugins;
}
Error | ELMSLN API

Error

×

Error message

  • Warning: Cannot modify header information - headers already sent by (output started at /var/www/html/elmsln_community/api.elmsln.org/includes/common.inc:2791) in drupal_send_headers() (line 1499 of /var/www/html/elmsln_community/api.elmsln.org/includes/bootstrap.inc).
  • Error: Call to undefined function apc_delete() in DrupalAPCCache->clear() (line 289 of /var/www/html/elmsln_community/api.elmsln.org/sites/all/modules/apc/drupal_apc_cache.inc).
The website encountered an unexpected error. Please try again later.