Uses
Uses | Description |
---|---|
wp-includes/plugin.php: _wp_call_all_hook() | Call the ‘all’ hook, which will process the functions hooked into it. |
Execute functions hooked on a specific action hook.
This function invokes all functions attached to action hook $tag
. It is possible to create new action hooks by simply calling this function, specifying the name of the new hook using the $tag
parameter.
You can pass extra arguments to the hooks, much like you can with apply_filters()
.
Example usage:
// The action callback function.
function example_callback( $arg1, $arg2 ) {
// (maybe) do something with the args.
}
add_action( 'example_action', 'example_callback', 10, 2 );
/*
* Trigger the actions by calling the 'example_callback()' function
* that's hooked onto `example_action` above.
*
* - 'example_action' is the action hook.
* - $arg1 and $arg2 are the additional arguments passed to the callback.
$value = do_action( 'example_action', $arg1, $arg2 );
(string) (Required) The name of the action to be executed.
(mixed) (Optional) Additional arguments which are passed on to the functions hooked to the action. Default empty.
File: wp-includes/plugin.php
function do_action( $tag, ...$arg ) { global $wp_filter, $wp_actions, $wp_current_filter; if ( ! isset( $wp_actions[ $tag ] ) ) { $wp_actions[ $tag ] = 1; } else { ++$wp_actions[ $tag ]; } // Do 'all' actions first. if ( isset( $wp_filter['all'] ) ) { $wp_current_filter[] = $tag; $all_args = func_get_args(); // phpcs:ignore PHPCompatibility.FunctionUse.ArgumentFunctionsReportCurrentValue.NeedsInspection _wp_call_all_hook( $all_args ); } if ( ! isset( $wp_filter[ $tag ] ) ) { if ( isset( $wp_filter['all'] ) ) { array_pop( $wp_current_filter ); } return; } if ( ! isset( $wp_filter['all'] ) ) { $wp_current_filter[] = $tag; } if ( empty( $arg ) ) { $arg[] = ''; } elseif ( is_array( $arg[0] ) && 1 === count( $arg[0] ) && isset( $arg[0][0] ) && is_object( $arg[0][0] ) ) { // Backward compatibility for PHP4-style passing of `array( &$this )` as action `$arg`. $arg[0] = $arg[0][0]; } $wp_filter[ $tag ]->do_action( $arg ); array_pop( $wp_current_filter ); }
Uses | Description |
---|---|
wp-includes/plugin.php: _wp_call_all_hook() | Call the ‘all’ hook, which will process the functions hooked into it. |
Used By | Description |
---|---|
wp-includes/comment.php: wp_check_comment_disallowed_list() | Checks if a comment contains disallowed characters or words. |
wp-includes/sitemaps.php: wp_sitemaps_get_server() | Retrieves the current Sitemaps server instance. |
wp-includes/functions.php: do_favicon() | Display the favicon.ico file content. |
wp-includes/rest-api/endpoints/class-wp-rest-attachments-controller.php: WP_REST_Attachments_Controller::insert_attachment() | Inserts the attachment post in the database. Does not update the attachment meta. |
wp-admin/includes/class-wp-ms-sites-list-table.php: WP_MS_Sites_List_Table::extra_tablenav() | Extra controls to be displayed between bulk actions and pagination. |
wp-includes/class-wp-recovery-mode-key-service.php: WP_Recovery_Mode_Key_Service::generate_and_store_recovery_mode_key() | Creates a recovery mode key. |
wp-includes/general-template.php: wp_body_open() | Fire the wp_body_open action. |
wp-includes/ms-site.php: wp_maybe_transition_site_statuses_on_update() | Triggers actions on site status updates. |
wp-includes/ms-site.php: wp_prepare_site_data() | Prepares site data for insertion or update in the database. |
wp-includes/ms-site.php: wp_insert_site() | Inserts a new site into the database. |
wp-includes/ms-site.php: wp_update_site() | Updates a site in the database. |
wp-includes/ms-site.php: wp_delete_site() | Deletes a site from the database. |
wp-includes/rest-api/endpoints/class-wp-rest-autosaves-controller.php: WP_REST_Autosaves_Controller::create_post_autosave() | Creates autosave for the specified post. |
wp-includes/script-loader.php: wp_common_block_scripts_and_styles() | Handles the enqueueing of block scripts and styles that are common to both the editor and the front-end. |
wp-admin/includes/post.php: the_block_editor_meta_box_post_form_hidden_fields() | Renders the hidden form required for the meta boxes form. |
wp-admin/includes/meta-boxes.php: register_and_do_post_meta_boxes() | Registers the default post meta boxes, and runs the |
wp-admin/includes/privacy-tools.php: wp_privacy_process_personal_data_export_page() | Intercept personal data exporter page Ajax responses in order to assemble the personal data export file. |
wp-admin/includes/privacy-tools.php: wp_privacy_generate_personal_data_export_file() | Generate the personal data export file. |
wp-admin/includes/privacy-tools.php: wp_privacy_process_personal_data_erasure_page() | Mark erasure requests as completed after processing is finished. |
wp-includes/class-wp-customize-manager.php: WP_Customize_Manager::trash_changeset_post() | Trash or delete a changeset post. |
wp-includes/taxonomy.php: clean_taxonomy_cache() | Clean the caches for a taxonomy. |
wp-includes/general-template.php: wp_enqueue_code_editor() | Enqueue assets needed by the code editor for the given settings. |
wp-includes/class-wp-roles.php: WP_Roles::init_roles() | Initializes all of the available roles. |
wp-includes/class-wp-editor.php: _WP_Editors::print_default_editor_scripts() | Print (output) all editor scripts and default settings. |
wp-includes/class-wp-customize-manager.php: WP_Customize_Manager::_publish_changeset_values() | Publish changeset values. |
wp-includes/class-wp-customize-manager.php: WP_Customize_Manager::save_changeset_post() | Save the post for the loaded changeset. |
wp-includes/theme.php: _wp_customize_publish_changeset() | Publishes a snapshot’s changes. |
wp-includes/rest-api/endpoints/class-wp-rest-users-controller.php: WP_REST_Users_Controller::delete_item() | Deletes a single user. |
wp-includes/rest-api/endpoints/class-wp-rest-users-controller.php: WP_REST_Users_Controller::create_item() | Creates a single user. |
wp-includes/rest-api/endpoints/class-wp-rest-users-controller.php: WP_REST_Users_Controller::update_item() | Updates a single user. |
wp-includes/rest-api/endpoints/class-wp-rest-revisions-controller.php: WP_REST_Revisions_Controller::delete_item() | Deletes a single revision. |
wp-includes/rest-api/endpoints/class-wp-rest-attachments-controller.php: WP_REST_Attachments_Controller::create_item() | Creates a single attachment. |
wp-includes/rest-api/endpoints/class-wp-rest-attachments-controller.php: WP_REST_Attachments_Controller::update_item() | Updates a single attachment. |
wp-includes/rest-api/endpoints/class-wp-rest-terms-controller.php: WP_REST_Terms_Controller::delete_item() | Deletes a single term from a taxonomy. |
wp-includes/rest-api/endpoints/class-wp-rest-terms-controller.php: WP_REST_Terms_Controller::create_item() | Creates a single term in a taxonomy. |
wp-includes/rest-api/endpoints/class-wp-rest-terms-controller.php: WP_REST_Terms_Controller::update_item() | Updates a single term from a taxonomy. |
wp-includes/rest-api/endpoints/class-wp-rest-posts-controller.php: WP_REST_Posts_Controller::create_item() | Creates a single post. |
wp-includes/rest-api/endpoints/class-wp-rest-posts-controller.php: WP_REST_Posts_Controller::update_item() | Updates a single post. |
wp-includes/rest-api/endpoints/class-wp-rest-posts-controller.php: WP_REST_Posts_Controller::delete_item() | Deletes a single post. |
wp-includes/rest-api/endpoints/class-wp-rest-comments-controller.php: WP_REST_Comments_Controller::update_item() | Updates a comment. |
wp-includes/rest-api/endpoints/class-wp-rest-comments-controller.php: WP_REST_Comments_Controller::delete_item() | Deletes a comment. |
wp-includes/rest-api/endpoints/class-wp-rest-comments-controller.php: WP_REST_Comments_Controller::create_item() | Creates a comment. |
wp-includes/class-wp-locale-switcher.php: WP_Locale_Switcher::change_locale() | Changes the site’s locale to the given one. |
wp-includes/class-wp-locale-switcher.php: WP_Locale_Switcher::switch_to_locale() | Switches the translations according to the given locale. |
wp-includes/class-wp-locale-switcher.php: WP_Locale_Switcher::restore_previous_locale() | Restores the translations according to the previous locale. |
wp-includes/comment.php: wp_check_comment_flood() | Checks whether comment flooding is occurring. |
wp-includes/class-wp-term-query.php: WP_Term_Query::get_terms() | Get terms, based on query_vars. |
wp-includes/class-wp-term-query.php: WP_Term_Query::parse_query() | Parse arguments passed to the term query with default query parameters. |
wp-includes/ms-network.php: clean_network_cache() | Removes a network from the object cache. |
wp-includes/functions.php: _deprecated_hook() | Marks a deprecated action or filter hook as deprecated and throws a notice. |
wp-includes/ms-load.php: ms_load_current_site_and_network() | Identifies the network and site of a requested domain and path and populates the corresponding network and site global objects as part of the multisite bootstrap process. |
wp-includes/rest-api.php: rest_get_server() | Retrieves the current REST server instance. |
wp-includes/class-wp-metadata-lazyloader.php: WP_Metadata_Lazyloader::queue_objects() | Adds objects to the metadata lazy-load queue. |
wp-includes/taxonomy.php: unregister_taxonomy() | Unregisters a taxonomy. |
wp-includes/post.php: unregister_post_type() | Unregisters a post type. |
wp-includes/customize/class-wp-customize-selective-refresh.php: WP_Customize_Selective_Refresh::handle_render_partials_request() | Handles the Ajax request to return the rendered partials for the requested placements. |
wp-includes/embed.php: enqueue_embed_scripts() | Enqueue embed iframe default CSS and JS & fire do_action(‘enqueue_embed_scripts’) |
wp-includes/user.php: get_password_reset_key() | Creates, stores, then returns a password reset key for user. |
wp-includes/comment.php: wp_handle_comment_submission() | Handles the submission of a comment, usually posted to wp-comments-post.php via a comment form. |
wp-includes/option.php: update_network_option() | Updates the value of a network option that was already added. |
wp-includes/option.php: add_network_option() | Adds a new network option. |
wp-includes/option.php: delete_network_option() | Removes a network option by name. |
wp-admin/includes/ajax-actions.php: wp_ajax_delete_inactive_widgets() | Ajax handler for removing inactive widgets. |
wp-includes/customize/class-wp-customize-nav-menu-item-control.php: WP_Customize_Nav_Menu_Item_Control::content_template() | JS/Underscore template for the control UI. |
wp-includes/functions.php: _deprecated_constructor() | Marks a constructor as deprecated and informs when it has been used. |
wp-admin/includes/class-wp-posts-list-table.php: WP_Posts_List_Table::column_default() | Handles the default column output. |
wp-admin/includes/class-wp-links-list-table.php: WP_Links_List_Table::column_default() | Handles the default column output. |
wp-admin/includes/class-wp-ms-themes-list-table.php: WP_MS_Themes_List_Table::column_default() | Handles default column output. |
wp-admin/includes/ajax-actions.php: wp_ajax_crop_image() | Ajax handler for cropping an image. |
wp-admin/includes/class-wp-ms-sites-list-table.php: WP_MS_Sites_List_Table::column_default() | Handles output for the default column. |
wp-admin/includes/class-wp-ms-sites-list-table.php: WP_MS_Sites_List_Table::column_plugins() | Handles the plugins column output. |
wp-admin/includes/class-wp-media-list-table.php: WP_Media_List_Table::column_default() | Handles output for the default column. |
wp-includes/class-wp-customize-manager.php: WP_Customize_Manager::set_post_value() | Override a setting’s value in the current customized state. |
wp-admin/includes/media.php: wp_media_attach_action() | Encapsulates the logic for Attach/Detach actions. |
wp-includes/class-wp-customize-panel.php: WP_Customize_Panel::maybe_render() | Check capabilities and render the panel. |
wp-login.php: login_footer() | Outputs the footer for the login page. |
wp-login.php: retrieve_password() | Handles sending password retrieval email to user. |
wp-login.php: login_header() | Output the login page header. |
wp-signup.php: show_user_form() | Display user registration form |
wp-signup.php: signup_another_blog() | Allow returning users to sign up for another site |
wp-signup.php: confirm_another_blog_signup() | Confirm a new site signup. |
wp-signup.php: signup_user() | Setup the new user signup process |
wp-signup.php: confirm_user_signup() | New user signup confirmation |
wp-signup.php: signup_blog() | Setup the new site signup |
wp-signup.php: confirm_blog_signup() | New site signup confirmation |
wp-signup.php: do_signup_header() | Prints signup_header via wp_head |
wp-signup.php: show_blog_form() | Generates and displays the Signup and Create Site forms |
wp-admin/install.php: display_setup_form() | Display installer setup form. |
wp-admin/includes/class-wp-automatic-updater.php: WP_Automatic_Updater::update() | Update an item, if appropriate. |
wp-admin/includes/class-wp-automatic-updater.php: WP_Automatic_Updater::run() | Kicks off the background update process, looping through all pending updates. |
wp-admin/includes/class-language-pack-upgrader.php: Language_Pack_Upgrader::bulk_upgrade() | Bulk upgrade language packs. |
wp-admin/includes/class-core-upgrader.php: Core_Upgrader::upgrade() | Upgrade WordPress core. |
wp-admin/includes/class-theme-upgrader.php: Theme_Upgrader::install() | Install a theme package. |
wp-admin/includes/class-theme-upgrader.php: Theme_Upgrader::bulk_upgrade() | Upgrade several themes at once. |
wp-admin/includes/class-plugin-upgrader.php: Plugin_Upgrader::bulk_upgrade() | Bulk upgrade several plugins at once. |
wp-admin/includes/class-plugin-upgrader.php: Plugin_Upgrader::install() | Install a plugin package. |
wp-admin/includes/class-wp-upgrader.php: WP_Upgrader::run() | Run an upgrade/installation. |
wp-admin/includes/class-wp-screen.php: WP_Screen::set_current_screen() | Makes the screen object the current screen. |
wp-admin/includes/class-wp-plugins-list-table.php: WP_Plugins_List_Table::single_row() | |
wp-admin/includes/export.php: export_wp() | Generates the WXR export file for download. |
wp-includes/capabilities.php: grant_super_admin() | Grants Super Admin privileges. |
wp-includes/capabilities.php: revoke_super_admin() | Revokes Super Admin privileges. |
wp-admin/includes/ms.php: wpmu_delete_user() | Delete a user from the network and remove from all sites. |
wp-includes/ms-deprecated.php: update_user_status() | Update the status of a user in the database. |
wp-admin/includes/class-wp-ms-themes-list-table.php: WP_MS_Themes_List_Table::single_row() | |
wp-admin/includes/schema.php: populate_options() | Create WordPress options and set the default values. |
wp-admin/includes/class-wp-theme-install-list-table.php: WP_Theme_Install_List_Table::display() | Displays the theme install table. |
wp-admin/includes/update.php: wp_plugin_update_row() | Displays update information for a plugin. |
wp-admin/includes/update.php: wp_theme_update_row() | Displays update information for a theme. |
wp-admin/includes/dashboard.php: wp_dashboard_right_now() | Dashboard widget that displays some basic stats about the site. |
wp-admin/includes/dashboard.php: wp_network_dashboard_right_now() | |
wp-admin/includes/dashboard.php: wp_dashboard_setup() | Registers dashboard widgets. |
wp-admin/includes/upgrade.php: wp_upgrade() | Runs WordPress Upgrade functions. |
wp-admin/includes/upgrade.php: wp_install() | Installs the site. |
wp-includes/option.php: register_setting() | Registers a setting and its data. |
wp-includes/option.php: unregister_setting() | Unregisters a setting. |
wp-admin/includes/plugin.php: uninstall_plugin() | Uninstall a single plugin. |
wp-admin/includes/plugin.php: activate_plugin() | Attempts activation of plugin in a “sandbox” and redirects on success. |
wp-admin/includes/plugin.php: deactivate_plugins() | Deactivate a single plugin or multiple plugins. |
wp-admin/includes/plugin.php: delete_plugins() | Remove directory and files of a plugin for a list of plugins. |
wp-admin/includes/user.php: edit_user() | Edit user settings based on contents of $_POST |
wp-admin/includes/user.php: wp_delete_user() | Remove user and optionally reassign posts and links to another user. |
wp-admin/includes/class-wp-plugin-install-list-table.php: WP_Plugin_Install_List_Table::display_tablenav() | |
wp-admin/includes/template.php: _wp_admin_html_begin() | |
wp-admin/includes/template.php: iframe_header() | Generic Iframe header for use with Thickbox |
wp-admin/includes/template.php: iframe_footer() | Generic Iframe footer for use with Thickbox |
wp-admin/includes/template.php: get_inline_data() | Adds hidden fields with the data for use in the inline editor for posts and pages. |
wp-admin/includes/class-wp-users-list-table.php: WP_Users_List_Table::extra_tablenav() | Output the controls to allow user roles to be changed in bulk. |
wp-admin/includes/media.php: edit_form_image_editor() | Displays the image and editor in the post editor |
wp-admin/includes/media.php: media_upload_form() | Outputs the legacy media upload form. |
wp-admin/includes/media.php: wp_iframe() | Outputs the iframe to display the media upload page. |
wp-admin/includes/post.php: _admin_notice_post_locked() | Outputs the HTML for the notice to say that someone else is editing or has taken over editing of this post. |
wp-admin/includes/post.php: wp_create_post_autosave() | Creates autosave data for the specified post from $_POST data. |
wp-admin/includes/ajax-actions.php: wp_ajax_heartbeat() | Ajax handler for the Heartbeat API. |
wp-admin/includes/ajax-actions.php: wp_ajax_save_widget() | Ajax handler for saving a widget. |
wp-admin/includes/ajax-actions.php: wp_ajax_nopriv_heartbeat() | Ajax handler for the Heartbeat API in the no-privilege context. |
wp-admin/includes/update-core.php: update_core() | Upgrades the core of WordPress. |
wp-admin/includes/meta-boxes.php: post_comment_status_meta_box() | Display comments status form fields. |
wp-admin/includes/meta-boxes.php: page_attributes_meta_box() | Display page attributes form fields. |
wp-admin/includes/meta-boxes.php: link_submit_meta_box() | Display link create form fields. |
wp-admin/includes/bookmark.php: wp_insert_link() | Inserts/updates links into/in the database. |
wp-admin/includes/meta-boxes.php: post_submit_meta_box() | Displays post submit form fields. |
wp-admin/includes/meta-boxes.php: attachment_submit_meta_box() | Display attachment submit form fields. |
wp-admin/includes/bookmark.php: wp_delete_link() | Deletes a specified link from the database. |
wp-admin/includes/class-wp-media-list-table.php: WP_Media_List_Table::extra_tablenav() | |
wp-admin/includes/class-wp-comments-list-table.php: WP_Comments_List_Table::column_default() | |
wp-admin/includes/class-wp-comments-list-table.php: WP_Comments_List_Table::extra_tablenav() | |
wp-admin/includes/class-wp-terms-list-table.php: WP_Terms_List_Table::inline_edit() | Outputs the hidden row displayed when inline editing |
wp-admin/includes/class-walker-nav-menu-edit.php: Walker_Nav_Menu_Edit::start_el() | Start the element output. |
wp-admin/includes/nav-menu.php: wp_nav_menu_update_menu_items() | Saves nav menu items |
wp-admin/includes/class-wp-posts-list-table.php: WP_Posts_List_Table::inline_edit() | Outputs the hidden row displayed when inline editing |
wp-admin/includes/class-wp-posts-list-table.php: WP_Posts_List_Table::extra_tablenav() | |
wp-admin/includes/class-custom-image-header.php: Custom_Image_Header::step_1() | Display first step of custom header image page. |
wp-admin/includes/class-custom-image-header.php: Custom_Image_Header::step_2() | Display second step of custom header image page. |
wp-admin/includes/ms.php: confirm_delete_users() | |
wp-admin/includes/class-custom-background.php: Custom_Background::handle_upload() | Handle an Image upload for the background image. |
wp-activate.php: do_activate_header() | Adds an action hook specific to this page. |
wp-includes/class-wp-user.php: WP_User::add_role() | Add role to user. |
wp-includes/class-wp-user.php: WP_User::remove_role() | Remove role from user. |
wp-includes/class-wp-user.php: WP_User::set_role() | Set the role of the user. |
wp-includes/class-wp-customize-manager.php: WP_Customize_Manager::customize_preview_init() | Print JavaScript settings. |
wp-includes/class-wp-customize-manager.php: WP_Customize_Manager::start_previewing_theme() | If the theme to be previewed isn’t the active theme, add filter callbacks to swap it out at runtime. |
wp-includes/class-wp-customize-manager.php: WP_Customize_Manager::stop_previewing_theme() | Stop previewing the selected theme. |
wp-includes/class-wp-customize-manager.php: WP_Customize_Manager::wp_loaded() | Register styles/scripts and initialize the preview of each setting |
wp-includes/theme.php: check_theme_switched() | Checks if a theme has been changed and runs ‘after_switch_theme’ hook on the next WP load. |
wp-includes/theme.php: switch_theme() | Switches the theme. |
wp-includes/l10n.php: load_textdomain() | Load a .mo file into the text domain $domain. |
wp-includes/l10n.php: unload_textdomain() | Unload translations for a text domain. |
wp-includes/pluggable.php: wp_verify_nonce() | Verifies that a correct security nonce was used with time limit. |
wp-includes/pluggable.php: wp_set_auth_cookie() | Sets the authentication cookies based on user ID. |
wp-includes/pluggable.php: wp_clear_auth_cookie() | Removes all of the cookies associated with authentication. |
wp-includes/pluggable.php: auth_redirect() | Checks if a user is logged in, if not it redirects them to the login page. |
wp-includes/pluggable.php: check_admin_referer() | Ensures intent by verifying that a user was referred from another admin page with the correct security nonce. |
wp-includes/pluggable.php: check_ajax_referer() | Verifies the Ajax request to prevent processing requests external of the blog. |
wp-includes/pluggable.php: wp_authenticate() | Authenticate a user, confirming the login credentials are valid. |
wp-includes/pluggable.php: wp_logout() | Log the current user out. |
wp-includes/pluggable.php: wp_validate_auth_cookie() | Validates authentication cookie. |
wp-includes/pluggable.php: wp_set_current_user() | Changes the current user by ID or name. |
wp-includes/pluggable.php: wp_mail() | Sends an email, similar to PHP’s mail function. |
wp-includes/general-template.php: wp_head() | Fire the wp_head action. |
wp-includes/general-template.php: wp_footer() | Fire the wp_footer action. |
wp-includes/general-template.php: wp_meta() | Theme container function for the ‘wp_meta’ action. |
wp-includes/general-template.php: get_header() | Load header template. |
wp-includes/general-template.php: get_footer() | Load footer template. |
wp-includes/general-template.php: get_sidebar() | Load sidebar template. |
wp-includes/general-template.php: get_template_part() | Loads a template part into a template. |
wp-includes/general-template.php: get_search_form() | Display search form. |
wp-includes/deprecated.php: delete_usermeta() | Remove user meta data. |
wp-includes/deprecated.php: update_usermeta() | Update metadata of user. |
wp-includes/class-wp-query.php: WP_Query::have_posts() | Determines whether there are more posts available in the loop. |
wp-includes/class-wp-query.php: WP_Query::the_comment() | Sets up the current comment. |
wp-includes/class-wp-query.php: WP_Query::get_posts() | Retrieves an array of posts based on query variables. |
wp-includes/class-wp-query.php: WP_Query::parse_tax_query() | Parses various taxonomy related query vars. |
wp-includes/load.php: shutdown_action_hook() | Runs just before PHP shuts down execution. |
wp-includes/class-http.php: WP_Http::_dispatch_request() | Dispatches a HTTP request to a supporting transport. |
wp-includes/class-http.php: WP_Http::request() | Send an HTTP request to a URI. |
wp-includes/functions.wp-scripts.php: wp_print_scripts() | Prints scripts in document head that are in the $handles queue. |
wp-includes/functions.php: _deprecated_function() | Mark a function as deprecated and inform when it has been used. |
wp-includes/functions.php: _deprecated_file() | Mark a file as deprecated and inform when it has been used. |
wp-includes/functions.php: _doing_it_wrong() | Mark something as being incorrectly called. |
wp-includes/functions.php: _deprecated_argument() | Mark a function argument as deprecated and inform when it has been used. |
wp-includes/functions.php: do_robots() | Displays the default robots.txt file content. |
wp-includes/functions.php: do_feed() | Load the feed template from the use of an action hook. |
wp-includes/widgets.php: wp_widgets_init() | Registers all of the default WordPress widgets on startup. |
wp-includes/class-wp-customize-section.php: WP_Customize_Section::maybe_render() | Check capabilities and render the section. |
wp-includes/taxonomy.php: _update_post_term_count() | Will update term count based on object types of the current taxonomy. |
wp-includes/taxonomy.php: _update_generic_term_count() | Will update term count based on number of objects. |
wp-includes/taxonomy.php: clean_object_term_cache() | Removes the taxonomy relationship to terms from the cache. |
wp-includes/taxonomy.php: wp_update_term() | Update term based on arguments provided. |
wp-includes/taxonomy.php: clean_term_cache() | Will remove all of the term IDs from the cache. |
wp-includes/taxonomy.php: wp_insert_term() | Add a new term to the database. |
wp-includes/taxonomy.php: wp_set_object_terms() | Create Term and Taxonomy Relationships. |
wp-includes/taxonomy.php: wp_remove_object_terms() | Remove term(s) associated with a given object. |
wp-includes/taxonomy.php: wp_delete_term() | Removes a term from the database. |
wp-includes/taxonomy.php: register_taxonomy() | Creates or modifies a taxonomy object. |
wp-includes/taxonomy.php: register_taxonomy_for_object_type() | Add an already registered taxonomy to an object type. |
wp-includes/taxonomy.php: unregister_taxonomy_for_object_type() | Remove an already registered taxonomy from an object type. |
wp-includes/class-wp-admin-bar.php: WP_Admin_Bar::add_menus() | |
wp-includes/class-wp-admin-bar.php: WP_Admin_Bar::initialize() | |
wp-includes/update.php: wp_version_check() | Check WordPress version against the newest version. |
wp-includes/functions.wp-styles.php: wp_print_styles() | Display styles that are in the $handles queue. |
wp-includes/admin-bar.php: wp_admin_bar_render() | Renders the admin bar to the page based on the $wp_admin_bar->menu member var. |
wp-includes/class-wp-customize-setting.php: WP_Customize_Setting::preview() | Add filters to supply the setting’s value when accessed. |
wp-includes/class-wp-customize-setting.php: WP_Customize_Setting::save() | Checks user capabilities and theme supports, and then saves the value of the setting. |
wp-includes/class-wp-customize-setting.php: WP_Customize_Setting::update() | Save the value of the setting, using the related API. |
wp-includes/option.php: set_site_transient() | Sets/updates the value of a site transient. |
wp-includes/option.php: delete_site_transient() | Deletes a site transient. |
wp-includes/option.php: set_transient() | Sets/updates the value of a transient. |
wp-includes/option.php: update_option() | Updates the value of an option that was already added. |
wp-includes/option.php: add_option() | Adds a new option. |
wp-includes/option.php: delete_option() | Removes option by name. Prevents removal of protected WordPress options. |
wp-includes/option.php: delete_transient() | Deletes a transient. |
wp-includes/class-wp-user-query.php: WP_User_Query::prepare_query() | Prepare the query variables. |
wp-includes/user.php: reset_password() | Handles resetting the user’s password. |
wp-includes/user.php: register_new_user() | Handles registering a new user. |
wp-includes/user.php: clean_user_cache() | Clean all user caches |
wp-includes/user.php: wp_insert_user() | Insert a user into the database. |
wp-includes/user.php: wp_signon() | Authenticates and logs a user in with ‘remember’ capability. |
wp-includes/post-thumbnail-template.php: get_the_post_thumbnail() | Retrieve the post thumbnail. |
wp-includes/media.php: wp_enqueue_media() | Enqueues all scripts, styles, settings, and templates necessary to use all media JS APIs. |
wp-includes/media.php: wp_playlist_shortcode() | Builds the Playlist shortcode output. |
wp-includes/post.php: clean_post_cache() | Will clean the post in the cache. |
wp-includes/post.php: clean_attachment_cache() | Will clean the attachment in the cache. |
wp-includes/post.php: _publish_post_hook() | Hook to schedule pings and enclosures when a post is published. |
wp-includes/post.php: wp_delete_attachment() | Trash or delete an attachment. |
wp-includes/post.php: wp_publish_post() | Publish a post by transitioning the post status. |
wp-includes/post.php: wp_transition_post_status() | Fires actions related to the transitioning of a post’s status. |
wp-includes/post.php: wp_untrash_post_comments() | Restore comments for a post from the Trash. |
wp-includes/post.php: wp_insert_post() | Insert or update a post. |
wp-includes/post.php: wp_delete_post() | Trash or delete a post or page. |
wp-includes/post.php: wp_trash_post() | Move a post or page to the Trash |
wp-includes/post.php: wp_untrash_post() | Restore a post or page from the Trash. |
wp-includes/post.php: wp_trash_post_comments() | Moves comments for a post to the Trash. |
wp-includes/post.php: stick_post() | Make a post sticky. |
wp-includes/post.php: unstick_post() | Un-stick a post. |
wp-includes/post.php: register_post_type() | Registers a post type. |
wp-includes/class-wp-rewrite.php: WP_Rewrite::set_permalink_structure() | Sets the main permalink structure for the site. |
wp-includes/revision.php: _wp_put_post_revision() | Inserts post data into the posts table as a post revision. |
wp-includes/revision.php: wp_restore_post_revision() | Restores a post to the specified revision. |
wp-includes/revision.php: wp_delete_post_revision() | Deletes a revision. |
wp-includes/ms-functions.php: add_existing_user_to_blog() | Add a user to a blog based on details from maybe_add_existing_user_to_blog(). |
wp-includes/ms-functions.php: wpmu_activate_signup() | Activate a signup. |
wp-includes/ms-functions.php: wpmu_create_user() | Create a user. |
wp-includes/ms-functions.php: wpmu_signup_blog() | Record site signup information for future activation. |
wp-includes/ms-functions.php: wpmu_signup_user() | Record user signup information for future activation. |
wp-includes/ms-functions.php: add_user_to_blog() | Adds a user to a blog, along with specifying the user’s role. |
wp-includes/ms-functions.php: remove_user_from_blog() | Remove a user from a blog. |
wp-includes/ms-blogs.php: switch_to_blog() | Switch the current blog. |
wp-includes/ms-blogs.php: restore_current_blog() | Restore the current blog, after calling switch_to_blog(). |
wp-includes/ms-site.php: clean_blog_cache() | Clean the blog cache |
wp-includes/ms-blogs.php: wpmu_update_blogs_date() | Update the last_updated field for the current site. |
wp-includes/nav-menu.php: wp_delete_nav_menu() | Delete a Navigation Menu. |
wp-includes/nav-menu.php: wp_update_nav_menu_object() | Save the properties of a menu or create a new menu with those properties. |
wp-includes/nav-menu.php: wp_update_nav_menu_item() | Save the properties of a menu item or create a new one. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::mt_getPostCategories() | Retrieve post categories. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::mt_setPostCategories() | Sets categories for a post. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::mt_supportedMethods() | Retrieve an array of methods supported by this server. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::mt_supportedTextFilters() | Retrieve an empty array because we don’t support per-post text filters. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::mt_getTrackbackPings() | Retrieve trackbacks sent to a given post. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::mt_publishPost() | Sets a post’s publish status to ‘publish’. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::pingback_ping() | Retrieves a pingback and registers it. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::pingback_extensions_getPingbacks() | Retrieve array of URLs that pingbacked the given URL. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::mw_editPost() | Edit a post. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::mw_getPost() | Retrieve post. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::mw_getRecentPosts() | Retrieve list of recent posts. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::mw_getCategories() | Retrieve the list of categories on a given blog. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::mw_newMediaObject() | Uploads a file, following your settings. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::mt_getRecentPostTitles() | Retrieve the post titles of recent posts. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::mt_getCategoryList() | Retrieve list of all categories on blog. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::blogger_getUserInfo() | Retrieve user’s data. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::blogger_getPost() | Retrieve post. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::blogger_getRecentPosts() | Retrieve list of recent posts. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::blogger_newPost() | Creates new post. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::blogger_editPost() | Edit a post. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::blogger_deletePost() | Remove a post. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::mw_newPost() | Create a new post. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getMediaItem() | Retrieve a media item by ID |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getMediaLibrary() | Retrieves a collection of media library items (or attachments) |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getPostFormats() | Retrieves a list of post formats used by the site. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getPostType() | Retrieves a post type |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getPostTypes() | Retrieves a post types |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getRevisions() | Retrieve revisions for a specific post. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_restoreRevision() | Restore a post revision |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::blogger_getUsersBlogs() | Retrieve blogs that user owns. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_deleteComment() | Delete a comment. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_editComment() | Edit comment. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getComments() | Retrieve comments. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_newComment() | Create new comment. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getCommentStatusList() | Retrieve all of the comment status. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getCommentCount() | Retrieve comment count. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getPostStatusList() | Retrieve post statuses. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getPageStatusList() | Retrieve page statuses. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getPages() | Retrieve Pages. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_newPage() | Create new page. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_deletePage() | Delete page. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_editPage() | Edit page. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getPageList() | Retrieve page list. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getAuthors() | Retrieve authors list. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getTags() | Get list of all tags |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_newCategory() | Create new category. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_deleteCategory() | Remove category. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_suggestCategories() | Retrieve category list. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getComment() | Retrieve comment. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getPosts() | Retrieve posts. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_newTerm() | Create a new term. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_editTerm() | Edit a term. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_deleteTerm() | Delete a term. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getTerm() | Retrieve a term. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getTerms() | Retrieve all terms for a taxonomy. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getTaxonomy() | Retrieve a taxonomy. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getTaxonomies() | Retrieve all taxonomies. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getUser() | Retrieve a user. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getUsers() | Retrieve users. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getProfile() | Retrieve information about the requesting user. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_editProfile() | Edit user’s profile. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getPage() | Retrieve page. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_newPost() | Create a new post for any registered post type. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_editPost() | Edit a post for any registered post type. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_deletePost() | Delete a post for any registered post type. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getPost() | Retrieve a post. |
wp-includes/class-wp-xmlrpc-server.php: wp_xmlrpc_server::wp_getUsersBlogs() | Retrieve the blogs of the user. |
wp-includes/class-wp-customize-control.php: WP_Customize_Control::maybe_render() | Check capabilities and render the control. |
wp-includes/widgets.php: dynamic_sidebar() | Display dynamic sidebar. |
wp-includes/widgets.php: the_widget() | Output an arbitrary widget as a template tag. |
wp-includes/widgets.php: wp_register_sidebar_widget() | Register an instance of a widget. |
wp-includes/widgets.php: wp_unregister_sidebar_widget() | Remove widget from sidebar. |
wp-includes/widgets.php: register_sidebar() | Builds the definition for a single sidebar and returns the ID. |
wp-includes/comment-template.php: comment_form() | Outputs a complete commenting form for use within a template. |
wp-includes/class-wp-customize-widgets.php: WP_Customize_Widgets::wp_ajax_update_widget() | Updates widget settings asynchronously. |
wp-includes/class-wp-customize-widgets.php: WP_Customize_Widgets::print_styles() | Calls admin_print_styles-widgets.php and admin_print_styles hooks to allow custom styles from plugins. |
wp-includes/class-wp-customize-widgets.php: WP_Customize_Widgets::print_scripts() | Calls admin_print_scripts-widgets.php and admin_print_scripts hooks to allow custom scripts from plugins. |
wp-includes/class-wp-customize-widgets.php: WP_Customize_Widgets::enqueue_scripts() | Enqueues scripts and styles for Customizer panel and export data to JavaScript. |
wp-includes/class-wp-customize-widgets.php: WP_Customize_Widgets::print_footer_scripts() | Calls admin_print_footer_scripts and admin_print_scripts hooks to allow custom scripts from plugins. |
wp-includes/class-wp-customize-widgets.php: WP_Customize_Widgets::customize_controls_init() | Ensures all widgets get loaded into the Customizer. |
wp-includes/script-loader.php: print_head_scripts() | Prints the script queue in the HTML head on admin pages. |
wp-includes/script-loader.php: wp_print_head_scripts() | Prints the script queue in the HTML head on the front end. |
wp-includes/script-loader.php: wp_print_footer_scripts() | Hooks to print the scripts and styles in the footer. |
wp-includes/script-loader.php: wp_enqueue_scripts() | Wrapper for do_action( ‘wp_enqueue_scripts’ ). |
wp-includes/comment.php: clean_comment_cache() | Removes a comment from the object cache. |
wp-includes/comment.php: wp_set_comment_status() | Sets the status of a comment. |
wp-includes/comment.php: wp_update_comment() | Updates an existing comment in the database. |
wp-includes/comment.php: wp_update_comment_count_now() | Updates the comment count for the post. |
wp-includes/comment.php: wp_new_comment() | Adds a new comment to the database. |
wp-includes/comment.php: wp_spam_comment() | Marks a comment as Spam |
wp-includes/comment.php: wp_unspam_comment() | Removes a comment from the Spam |
wp-includes/comment.php: wp_insert_comment() | Inserts a comment into the database. |
wp-includes/comment.php: wp_transition_comment_status() | Call hooks for when a comment status transition occurs. |
wp-includes/comment.php: wp_delete_comment() | Trashes or deletes a comment. |
wp-includes/comment.php: wp_trash_comment() | Moves a comment to the Trash |
wp-includes/comment.php: wp_untrash_comment() | Removes a comment from the Trash |
wp-includes/comment.php: wp_allow_comment() | Validates whether this comment is allowed to be made. |
wp-includes/meta.php: delete_metadata() | Deletes metadata for the specified object. |
wp-includes/meta.php: update_metadata_by_mid() | Updates metadata by meta ID. |
wp-includes/meta.php: delete_metadata_by_mid() | Deletes metadata by meta ID. |
wp-includes/meta.php: add_metadata() | Adds metadata for the specified object. |
wp-includes/meta.php: update_metadata() | Updates metadata for the specified object. If no value already exists for the specified object ID and metadata key, the metadata will be added. |
wp-includes/class-wp-editor.php: _WP_Editors::enqueue_scripts() | |
wp-includes/class-wp-editor.php: _WP_Editors::editor_js() | Print (output) the TinyMCE configuration and initialization scripts. |
wp-includes/class-wp-editor.php: _WP_Editors::editor() | Outputs the HTML for a single instance of the editor. |
wp-includes/media-template.php: wp_print_media_templates() | Prints the templates used in the media manager. |
Version | Description |
---|---|
5.3.0 | Formalized the existing and already documented ...$arg parameter by adding it to the function signature. |
1.2.0 | Introduced. |
© 2003–2019 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/functions/do_action