You are here

function _coder_style_core_global_regex in Coder 6.2

Same name and namespace in other branches
  1. 5.2 includes/coder_style.inc \_coder_style_core_global_regex()
  2. 5 includes/coder_style.inc \_coder_style_core_global_regex()
  3. 6 includes/coder_style.inc \_coder_style_core_global_regex()
1 call to _coder_style_core_global_regex()
coder_style_reviews in includes/coder_style.inc
Implementation of hook_reviews().

File

includes/coder_style.inc, line 184
This include file implements coder functionality for Drupal Standards.

Code

function _coder_style_core_global_regex() {
  static $coreglobalregex, $coreglobalvars;
  if (!isset($coreglobalregex)) {

    // Note: there's a little extra overhead in formatting this list as an
    // array, but I think it makes it more readable and maintainable.
    $coreglobalvars = array(
      // From the Drupal 5 includes/ directory.
      'active_db',
      'base_path',
      'base_root',
      'base_url',
      'conf',
      'custom_theme',
      'db_prefix',
      'db_type',
      'db_url',
      'form_button_counter',
      'form_submitted',
      'form_values',
      'install_locale',
      'installed_profile',
      'language',
      'last_result',
      'locale',
      'multibyte',
      'pager_page_array',
      'pager_total',
      'pager_total_items',
      'profile',
      'queries',
      'sidebar_indicator',
      'theme',
      'theme_engine',
      'theme_key',
      'theme_path',
      'timers',
      'user',
      'xrds_services',
      'xrds_open_elements',
      'xrds_current_service',
      // From the Drupal 5 modules/ directory -
      // Note: IMHO these should not be allowed, but until we fix core,
      // other modules will need them.
      'channel',
      'element',
      'forum_topic_list_header',
      'id',
      'image',
      'item',
      'items',
      'last_change',
      'last_nid',
      'nid',
      'recent_activity',
      'tag',
    );
    $coreglobalregex = implode('|', $coreglobalvars);
  }
  return $coreglobalregex;
}