You are here

function views_plugin_display::is_identifier_unique in Views (for Drupal 7) 6.3

Same name and namespace in other branches
  1. 6.2 plugins/views_plugin_display.inc \views_plugin_display::is_identifier_unique()
  2. 7.3 plugins/views_plugin_display.inc \views_plugin_display::is_identifier_unique()

Check if the provided identifier is unique.

File

plugins/views_plugin_display.inc, line 2538
Contains the base display plugin.

Class

views_plugin_display
The default display plugin handler. Display plugins handle options and basic mechanisms for different output methods.

Code

function is_identifier_unique($id, $identifier) {
  foreach (views_object_types() as $type => $info) {
    foreach ($this
      ->get_handlers($type) as $key => $handler) {
      if ($handler
        ->can_expose() && $handler
        ->is_exposed()) {
        if ($id != $key && $identifier == $handler->options['expose']['identifier']) {
          return FALSE;
        }
      }
    }
  }
  return TRUE;
}