function module_exists

Determines whether a given module exists.

Parameters

$module: The name of the module (without the .module extension).

Return value

TRUE if the module is both installed and enabled.

92 calls to module_exists()
aggregator_sanitize_configuration in drupal/core/modules/aggregator/aggregator.module
Checks and sanitizes the aggregator configuration.
aggregator_save_category in drupal/core/modules/aggregator/aggregator.module
Adds/edits/deletes aggregator categories.
aggregator_save_feed in drupal/core/modules/aggregator/aggregator.module
Adds/edits/deletes an aggregator feed.
bartik_process_html in drupal/core/themes/bartik/template.php
Implements hook_process_HOOK() for html.tpl.php.
bartik_process_page in drupal/core/themes/bartik/template.php
Implements hook_process_HOOK() for page.tpl.php.

... See full list

1 string reference to 'module_exists'
locale in drupal/core/modules/locale/locale.module
Provides interface translation services.

File

drupal/core/includes/module.inc, line 341
API for loading and interacting with Drupal modules.

Code

function module_exists($module) {
  $list = module_list();
  return isset($list[$module]);
}