wp_doing_ajax()
Determines whether the current request is a WordPress Ajax request.
Description #Description
Return #Return
(bool) True if it's a WordPress Ajax request, false otherwise.
Source #Source
File: wp-includes/load.php
function wp_doing_ajax() { /** * Filters whether the current request is a WordPress Ajax request. * * @since 4.7.0 * * @param bool $wp_doing_ajax Whether the current request is a WordPress Ajax request. */ return apply_filters( 'wp_doing_ajax', defined( 'DOING_AJAX' ) && DOING_AJAX ); }
Expand full source code Collapse full source code View on Trac
Changelog #Changelog
Version | Description |
---|---|
4.7.0 | Introduced. |
Related #Related
Uses #Uses
Uses | Description |
---|---|
wp-includes/load.php: wp_doing_ajax |
Filters whether the current request is a WordPress Ajax request. |
wp-includes/plugin.php: apply_filters() |
Calls the callback functions that have been added to a filter hook. |
Used By #Used By
Used By | Description |
---|---|
wp-includes/load.php: is_protected_endpoint() |
Determines whether we are currently on an endpoint that should be protected against WSODs. |
wp-includes/load.php: is_protected_ajax_action() |
Determines whether we are currently handling an AJAX action that should be protected against WSODs. |
wp-includes/comment.php: wp_check_comment_flood() |
Checks whether comment flooding is occurring. |
wp-admin/includes/class-wp-comments-list-table.php: WP_Comments_List_Table::handle_row_actions() |
Generate and display row actions links. |
wp-admin/includes/class-wp-terms-list-table.php: WP_Terms_List_Table::handle_row_actions() |
Generates and displays row action links. |
wp-admin/includes/theme.php: themes_api() |
Retrieves theme installer pages from the WordPress.org Themes API. |
wp-admin/includes/class-wp-list-table.php: WP_List_Table::set_pagination_args() |
An internal method that sets all the necessary pagination arguments |
wp-admin/includes/ms.php: check_upload_size() |
Determine if uploaded file exceeds space quota. |
wp-admin/includes/dashboard.php: wp_dashboard_cached_rss_widget() |
Checks to see if all of the feed url in $check_urls are cached. |
wp-admin/includes/class-wp-comments-list-table.php: WP_Comments_List_Table::prepare_items() | |
wp-admin/includes/class-wp-terms-list-table.php: WP_Terms_List_Table::column_name() | |
wp-includes/class-wp-customize-manager.php: WP_Customize_Manager::doing_ajax() |
Return true if it’s an Ajax request. |
wp-includes/theme.php: _wp_customize_include() |
Includes and instantiates the WP_Customize_Manager class. |
wp-includes/pluggable.php: check_ajax_referer() |
Verifies the Ajax request to prevent processing requests external of the blog. |
wp-includes/pluggable.php: wp_validate_auth_cookie() |
Validates authentication cookie. |
wp-includes/load.php: wp_debug_mode() |
Set PHP error reporting based on WordPress debug settings. |
wp-includes/functions.php: wp_send_json() |
Send a JSON response back to an Ajax request. |
wp-includes/functions.php: wp_die() |
Kills WordPress execution and displays HTML page with an error message. |
wp-includes/class-wp-ajax-response.php: WP_Ajax_Response::send() |
Display XML formatted responses. |
wp-includes/option.php: wp_user_settings() |
Saves and restores user interface settings stored in a cookie. |
wp-includes/comment.php: wp_allow_comment() |
Validates whether this comment is allowed to be made. |