module_implements
- Versions
- 5 – 6
module_implements($hook, $sort = FALSE,$refresh= FALSE)- 7
module_implements($hook, $sort = FALSE, $reset = FALSE)
Determine which modules are implementing a hook.
Parameters
$hook The name of the hook (e.g. "help" or "menu").
$sort By default, modules are ordered by weight and filename, settings this option to TRUE, module list will be ordered by module name.
$refresh For internal use only: Whether to force the stored list of hook implementations to be regenerated (such as after enabling a new module, before processing hook_enable).
Return value
An array with the names of the modules which are implementing this hook.
Related topics
- Hooks
- Allow modules to interact with the Drupal core.
▾ 126 functions call module_implements()
- block_list in core/modules/block/block.module
- Return all blocks in the specified region for the current user.
- captcha_examples in contrib/captcha/captcha.admin.inc
- Funtion for generating a page with CAPTCHA examples.
- comment_invoke_comment in core/modules/comment/comment.module
- Invoke a hook_comment() operation in all modules.
- content_build_modes in contrib/cck/content.module
- Registry of available node build modes.
- content_types_overview in contrib/cck/includes/content.admin.inc
- Menu callback; replacement for node_overview_types().
- ctools_context_convert_context in contrib/ctools/includes/context.inc
- Let the context convert an argument based upon the converter that was given.
- ctools_get_style_base_types in contrib/ctools/includes/stylizer.inc
- Fetch metadata about all of the style base types that are available.
- ctools_plugin_api_info in contrib/ctools/includes/plugins.inc
- Get an array of information about modules that support an API.
- ctools_plugin_get_directories in contrib/ctools/includes/plugins.inc
- Get a list of directories to search for plugins of the given type.
- ctools_plugin_load_hooks in contrib/ctools/includes/plugins.inc
- Load plugin info for the provided hook; this is handled separately from plugins from files.
- ctools_search_form_content_type_edit_form in contrib/ctools/plugins/content_types/search/search_form.inc
- Returns an edit form for custom type settings.
- ctools_search_result_content_type_edit_form in contrib/ctools/plugins/content_types/search/search_result.inc
- Returns an edit form for custom type settings.
- drupal_alter in core/includes/common.inc
- Hands off alterable variables to type-specific *_alter implementations.
- drupal_get_schema in core/includes/common.inc
- Get the schema definition of a table, or the whole database schema.
- drush_cache_clear_types in contrib/drush/commands/core/clear.cache.inc
- emfield_implement_types in contrib/emfield/emfield.module
- This returns a list of content types that are implemented by emfield.
- emfield_settings in contrib/emfield/emfield.admin.inc
- Callback for admin/content/emfield.
- emthumb_fetch_remote_thumbnail in contrib/emfield/contrib/emthumb/emthumb.module
- This fetches the thumbnail from the remote provider for local storage.
- features_get_components in contrib/features/features.module
- Returns the array of supported components.
- features_get_default in contrib/features/features.export.inc
- Get defaults for a given module/component pair.
- features_get_default_hooks in contrib/features/features.export.inc
- Gets the available default hooks keyed by components.
- features_get_default_map in contrib/features/features.export.inc
- Get a map of components to their providing modules.
- features_include in contrib/features/features.module
- Load includes for any modules that implement the features API and load includes for those provided by features.
- fieldgroup_build_content in contrib/cck/modules/fieldgroup/fieldgroup.module
- Build the node content element needed to render a fieldgroup.
- fieldgroup_form_alter in contrib/cck/modules/fieldgroup/fieldgroup.module
- Implementation of hook_form_alter()
- field_file_load in contrib/filefield/field_file.inc
- Load a file from the database.
- field_file_save in contrib/filefield/field_file.inc
- Save a node file. Delete items if necessary and set new items as permanent.
- field_file_save_file in contrib/filefield/field_file.inc
- Save a file into a file node after running all the associated validators.
- field_file_save_upload in contrib/filefield/field_file.inc
- Save a file upload to a new location. The source file is validated as a proper upload and handled as such. By implementing hook_file($op = 'insert'), modules are able to act on the file upload and to add their own properties to the file.
- flag_get_default_flags in contrib/flag/flag.module
- Retrieve a list of flags defined by modules.
- flag_get_link_types in contrib/flag/flag.module
- Return an array of link types provided by modules.
- flag_token_get_list in contrib/flag/includes/flag.token.inc
- This is a replacement for Token's token_get_list().
- gmap_module_invoke in contrib/gmap/gmap.module
- Invokes hook_gmap() in every module.
- help_links_as_list in core/modules/help/help.admin.inc
- help_menu in core/modules/help/help.module
- Implementation of hook_menu().
- imageapi_get_available_toolkits in contrib/imageapi/imageapi.module
- Return a list of available toolkits.
- imagecache_action_definitions in contrib/imagecache/imagecache.module
- Pull in actions exposed by other modules using hook_imagecache_actions().
- image_import_form in contrib/image/contrib/image_import/image_import.pages.inc
- Form generating function for the image import page.
- location_invoke_locationapi in contrib/location/location.module
- Invoke a hook_locationapi() operation on all modules.
- menu_router_build in core/includes/menu.inc
- Collect, alter and store the menu definitions.
- mimemail_get_engines in contrib/mimemail/mimemail.module
- Retreives a list of all available mailer engines.
- mimemail_incoming in contrib/mimemail/includes/mimemail.incoming.inc
- Parses an externally received message.
- mimemail_prepare_message in contrib/mimemail/mimemail.module
- Sends a mime-encoded e-mail.
- module_disable in core/includes/module.inc
- Disable a given set of modules.
- module_enable in core/includes/module.inc
- Enable a given list of modules.
- module_invoke_all in core/includes/module.inc
- Invoke a hook in all enabled modules that implement it.
- mollom_admin_form_options in contrib/mollom/mollom.admin.inc
- Return registered forms as an array suitable for a 'checkboxes' form element #options property.
- mollom_form_list in contrib/mollom/mollom.module
- Returns a list of protectable forms registered via hook_mollom_form_info().
- nodewords_get_possible_tags in contrib/nodewords/nodewords.module
- Query all the modules implementing meta tags and return the list of meta tags.
- nodewords_load_all_includes in contrib/nodewords/nodewords.module
- Load an include file for each of the modules that have support for Nodewords.
- nodewords_replace_tokens in contrib/nodewords/nodewords.module
- nodewords_requirements in contrib/nodewords/nodewords.install
- Implements hook_requirements().
- node_access_rebuild in core/modules/node/node.module
- Rebuild the node access database. This is occasionally needed by modules that make system-wide changes to access levels.
- node_access_write_grants in core/modules/node/node.module
- Writes a list of grants to the database, deleting any previously saved ones.
- node_invoke_nodeapi in core/modules/node/node.module
- Invoke a hook_nodeapi() operation in all modules.
- page_manager_blog in contrib/ctools/page_manager/plugins/tasks/blog.inc
- Entry point for our overridden node edit.
- page_manager_blog_user in contrib/ctools/page_manager/plugins/tasks/blog_user.inc
- Entry point for our overridden user view.
- page_manager_contact_site in contrib/ctools/page_manager/plugins/tasks/contact_site.inc
- Entry point for our overridden node edit.
- page_manager_contact_user in contrib/ctools/page_manager/plugins/tasks/contact_user.inc
- Entry point for our overridden user view.
- page_manager_node_view in contrib/ctools/page_manager/plugins/tasks/node_view.inc
- Entry point for our overridden node view.
- page_manager_poll in contrib/ctools/page_manager/plugins/tasks/poll.inc
- Entry point for our overridden node edit.
- page_manager_search_menu_alter in contrib/ctools/page_manager/plugins/tasks/search.inc
- Callback defined by page_manager_search_page_manager_tasks().
- page_manager_search_page in contrib/ctools/page_manager/plugins/tasks/search.inc
- Entry point for our overridden node view.
- page_manager_search_subtasks in contrib/ctools/page_manager/plugins/tasks/search.inc
- Task callback to get all subtasks.
- page_title_page_get_title in contrib/page_title/page_title.module
- Determines what title should be sent to the page template.
- search_invoke_preprocess in core/modules/search/search.module
- Invokes hook_search_preprocess() in modules.
- search_menu in core/modules/search/search.module
- Implementation of hook_menu().
- system_install in core/modules/system/system.install
- Implementation of hook_install().
- system_performance_settings in core/modules/system/system.admin.inc
- Form builder; Configure site performance settings. See alsosystem_settings_form()
- template_preprocess_calendar in contrib/calendar/theme/theme.inc
- Display a view as a calendar.
- template_preprocess_panels_dashboard in contrib/panels/includes/callbacks.inc
- token_get_list in contrib/token/token.module
- A helper function that retrieves all currently exposed tokens, and merges them recursively. This is only necessary when building the token listing -- during actual value replacement, only tokens in a particular domain are requested and a normal...
- uc_file_admin_files_form_action in contrib/ubercart/uc_file/uc_file.admin.inc
- Perform file action (upload, delete, hooked in actions).
- uc_file_admin_files_form_action_submit in contrib/ubercart/uc_file/uc_file.admin.inc
- @see uc_file_admin_files_action()
- uc_file_admin_files_form_action_validate in contrib/ubercart/uc_file/uc_file.admin.inc
- @see uc_file_admin_files_form_action()
- uc_file_admin_files_form_show_files in contrib/ubercart/uc_file/uc_file.admin.inc
- Display all files that may be purchased and downloaded for administration.
- uc_paypal_wps_form in contrib/ubercart/payment/uc_paypal/uc_paypal.module
- uc_quote_get_shipping_types in contrib/ubercart/shipping/uc_quote/uc_quote.module
- Return an array of shipping types.
- update_main_prepare in contrib/drush/commands/core/drupal/update_7.inc
- views1_convert_style in contrib/views/includes/convert.inc
- views1_import in contrib/views/includes/convert.inc
- Convert a Views 1 view to a Views 2 view.
- views_discover_handlers in contrib/views/includes/handlers.inc
- Builds and return a list of all handlers available in the system.
- views_discover_plugins in contrib/views/includes/plugins.inc
- Builds and return a list of all plugins available in the system.
- views_export_export in contrib/views/views_export/views_export.module
- Page callback to export views in bulk.
- views_get_module_apis in contrib/views/views.module
- Get a list of modules that support the current views API.
- views_handler_dependencies in contrib/features/includes/features.views.inc
- Provides an array that maps hook_views_data() tables to modules.
- views_plugin_dependencies in contrib/features/includes/features.views.inc
- Provides an array that maps hook_views_plugins() to modules.
- watchdog in core/includes/bootstrap.inc
- Log a system message.
- webform_components in contrib/webform/webform.module
- Get a list of all available component definitions.
- webform_component_insert in contrib/webform/includes/webform.components.inc
- Insert a new component into the database.
- webform_component_update in contrib/webform/includes/webform.components.inc
- Update an existing component with new values.
- webform_get_submissions in contrib/webform/includes/webform.submissions.inc
- Return all the submissions for a particular node.
- webform_submission_insert in contrib/webform/includes/webform.submissions.inc
- webform_submission_update in contrib/webform/includes/webform.submissions.inc
- wysiwyg_get_directories in contrib/wysiwyg/wysiwyg.module
- Return a list of directories by modules implementing wysiwyg_include_directory().
- xmlsitemap_check_status in contrib/xmlsitemap/xmlsitemap.inc
- Check the status of all hook_requirements() from any xmlsitemap modules.
- xmlsitemap_generate_chunk in contrib/xmlsitemap/xmlsitemap.generate.inc
- Generate one page (chunk) of the sitemap.
- xmlsitemap_node_view_access in contrib/xmlsitemap/xmlsitemap_node/xmlsitemap_node.module
- Determine whether a user may view the specified node.
- _admin_menu_rebuild_links in contrib/admin_menu/admin_menu.inc
- The key function that builds the menu links whenever there is a menu rebuild.
- _captcha_available_challenge_types in contrib/captcha/captcha.admin.inc
- Return an array with the available CAPTCHA types, for use as options array for a select form elements.
- _ctools_context_get_converters in contrib/ctools/includes/context.inc
- Get a list of converters available for a given context.
- _ctools_export_get_defaults in contrib/ctools/includes/export.inc
- Call the hook to get all default objects of the given type from the export. If configured properly, this could include loading up an API to get default objects.
- _date_api_fields in contrib/date/includes/date_api_fields.inc
- Identify all potential date/timestamp fields.
- _date_format_types_build in contrib/date/date_api.module
- Builds and returns the list of available date format types.
- _db_rewrite_sql in core/includes/database.inc
- Helper function for db_rewrite_sql.
- _devel_node_access_module_invoke_all in contrib/devel/devel_node_access.module
- _drush_bootstrap_drupal_full in contrib/drush/includes/environment.inc
- Attempt to load the full Drupal system.
- _drush_core_search_status in contrib/drush/commands/core/search.drush.inc
- _element_info in core/includes/form.inc
- Retrieve the default properties for the defined element type.
- _emfield_emfield_field in contrib/emfield/emfield.cck.inc
- Implementation of hook_emfield_field(). This in turn is a callback for hook_field().
- _emfield_emfield_widget in contrib/emfield/emfield.cck.inc
- Helper function for emfield_emfield_widget, which in turn is a help function for all emfields that implement hook_widget(). This creates default widget handling for all the Embedded Media Fields. Helper modules are expected to call this function to...
- _emfield_emfield_widget_settings in contrib/emfield/emfield.cck.inc
- _emfield_nodeapi_rss in contrib/emfield/emfield.rss.inc
- _event_block_upcoming in contrib/event/event.module
- Helper function for upcoming events block. Can be called by other modules.See alsoevent_block_upcoming
- _gmap_parse_macro in contrib/gmap/gmap_parse_macro.inc
- _image_imagemagick_alter_invoke in contrib/image/image.imagemagick.inc
- Invoke hook_imagemagick_alter().
- _nodewords_detect_type_and_id in contrib/nodewords/nodewords.module
- Try to guess the $type and $id by looking at $_GET['q'].
- _scheduler_scheduler_api in contrib/scheduler/scheduler.module
- Scheduler API to perform actions when nodes are (un)published
- _theme_build_registry in core/includes/theme.inc
- Rebuild the hook theme_registry cache.
- _uc_file_download_transfer in contrib/ubercart/uc_file/uc_file.pages.inc
- Send the file's binary data to a user via HTTP and update the uc_file_users table.
- _uc_file_download_validate in contrib/ubercart/uc_file/uc_file.pages.inc
- Perform first-pass authorization. Call authorization hooks afterwards.
- _uc_price_get_handlers in contrib/ubercart/uc_store/includes/uc_price.inc
- Return an array of price handler data.
- _user_features_permission_map in contrib/features/includes/features.user.inc
- Generate a perm to module mapping.
- _views_discover_default_views in contrib/views/includes/cache.inc
- Scan all modules for default views and rebuild the default views cache.
- _views_fetch_data in contrib/views/includes/cache.inc
- Fetch Views' data from the cache
- _webform_select_options_info in contrib/webform/components/select.inc
- Load Webform select option info from 3rd party modules.
Code
core/includes/module.inc, line 415
<?php
function module_implements($hook, $sort = FALSE, $refresh = FALSE) {
static $implementations;
if ($refresh) {
$implementations = array();
return;
}
if (!isset($implementations[$hook])) {
$implementations[$hook] = array();
$list = module_list(FALSE, TRUE, $sort);
foreach ($list as $module) {
if (module_hook($module, $hook)) {
$implementations[$hook][] = $module;
}
}
}
// The explicit cast forces a copy to be made. This is needed because
// $implementations[$hook] is only a reference to an element of
// $implementations and if there are nested foreaches (due to nested node
// API calls, for example), they would both manipulate the same array's
// references, which causes some modules' hooks not to be called.
// See also http://www.zend.com/zend/art/ref-count.php.
return (array)$implementations[$hook];
}
?>


