Docs: Replace "AJAX" with "Ajax" in DocBlocks and comments, per the spelling glossary.
Props mukesh27, sabernhardt, SergeyBiryukov. Fixes #50064. Built from https://develop.svn.wordpress.org/trunk@48168 git-svn-id: http://core.svn.wordpress.org/trunk@47937 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
d38a32bfac
commit
56342b8e8f
|
@ -331,7 +331,7 @@ function wp_ajax_autocomplete_user() {
|
|||
}
|
||||
|
||||
/**
|
||||
* Handles AJAX requests for community events
|
||||
* Handles Ajax requests for community events
|
||||
*
|
||||
* @since 4.8.0
|
||||
*/
|
||||
|
|
|
@ -178,8 +178,8 @@ class WP_Site_Health {
|
|||
/**
|
||||
* Run the SQL version checks.
|
||||
*
|
||||
* These values are used in later tests, but the part of preparing them is more easily managed early
|
||||
* in the class for ease of access and discovery.
|
||||
* These values are used in later tests, but the part of preparing them is more easily managed
|
||||
* early in the class for ease of access and discovery.
|
||||
*
|
||||
* @since 5.2.0
|
||||
*
|
||||
|
@ -212,11 +212,11 @@ class WP_Site_Health {
|
|||
/**
|
||||
* Test if `wp_version_check` is blocked.
|
||||
*
|
||||
* It's possible to block updates with the `wp_version_check` filter, but this can't be checked during an
|
||||
* AJAX call, as the filter is never introduced then.
|
||||
* It's possible to block updates with the `wp_version_check` filter, but this can't be checked
|
||||
* during an Ajax call, as the filter is never introduced then.
|
||||
*
|
||||
* This filter overrides a normal page request if it's made by an admin through the AJAX call with the
|
||||
* right query argument to check for this.
|
||||
* This filter overrides a normal page request if it's made by an admin through the Ajax call
|
||||
* with the right query argument to check for this.
|
||||
*
|
||||
* @since 5.2.0
|
||||
*/
|
||||
|
@ -233,8 +233,8 @@ class WP_Site_Health {
|
|||
/**
|
||||
* Tests for WordPress version and outputs it.
|
||||
*
|
||||
* Gives various results depending on what kind of updates are available, if any, to encourage the
|
||||
* user to install security updates as a priority.
|
||||
* Gives various results depending on what kind of updates are available, if any, to encourage
|
||||
* the user to install security updates as a priority.
|
||||
*
|
||||
* @since 5.2.0
|
||||
*
|
||||
|
@ -334,7 +334,8 @@ class WP_Site_Health {
|
|||
/**
|
||||
* Test if plugins are outdated, or unnecessary.
|
||||
*
|
||||
* The tests checks if your plugins are up to date, and encourages you to remove any that are not in use.
|
||||
* The tests checks if your plugins are up to date, and encourages you to remove any
|
||||
* that are not in use.
|
||||
*
|
||||
* @since 5.2.0
|
||||
*
|
||||
|
@ -465,8 +466,9 @@ class WP_Site_Health {
|
|||
/**
|
||||
* Test if themes are outdated, or unnecessary.
|
||||
*
|
||||
* The tests checks if your site has a default theme (to fall back on if there is a need), if your themes
|
||||
* are up to date and, finally, encourages you to remove any themes that are not needed.
|
||||
* Сhecks if your site has a default theme (to fall back on if there is a need),
|
||||
* if your themes are up to date and, finally, encourages you to remove any themes
|
||||
* that are not needed.
|
||||
*
|
||||
* @since 5.2.0
|
||||
*
|
||||
|
@ -1408,11 +1410,11 @@ class WP_Site_Health {
|
|||
/**
|
||||
* Test if debug information is enabled.
|
||||
*
|
||||
* When WP_DEBUG is enabled, errors and information may be disclosed to site visitors, or it may be
|
||||
* logged to a publicly accessible file.
|
||||
* When WP_DEBUG is enabled, errors and information may be disclosed to site visitors,
|
||||
* or logged to a publicly accessible file.
|
||||
*
|
||||
* Debugging is also frequently left enabled after looking for errors on a site, as site owners do
|
||||
* not understand the implications of this.
|
||||
* Debugging is also frequently left enabled after looking for errors on a site,
|
||||
* as site owners do not understand the implications of this.
|
||||
*
|
||||
* @since 5.2.0
|
||||
*
|
||||
|
@ -1589,8 +1591,8 @@ class WP_Site_Health {
|
|||
/**
|
||||
* Test if scheduled events run as intended.
|
||||
*
|
||||
* If scheduled events are not running, this may indicate something with WP_Cron is not working as intended,
|
||||
* or that there are orphaned events hanging around from older code.
|
||||
* If scheduled events are not running, this may indicate something with WP_Cron is not working
|
||||
* as intended, or that there are orphaned events hanging around from older code.
|
||||
*
|
||||
* @since 5.2.0
|
||||
*
|
||||
|
@ -1661,8 +1663,9 @@ class WP_Site_Health {
|
|||
/**
|
||||
* Test if WordPress can run automated background updates.
|
||||
*
|
||||
* Background updates in WordPress are primarily used for minor releases and security updates. It's important
|
||||
* to either have these working, or be aware that they are intentionally disabled for whatever reason.
|
||||
* Background updates in WordPress are primarily used for minor releases and security updates.
|
||||
* It's important to either have these working, or be aware that they are intentionally disabled
|
||||
* for whatever reason.
|
||||
*
|
||||
* @since 5.2.0
|
||||
*
|
||||
|
@ -1734,8 +1737,9 @@ class WP_Site_Health {
|
|||
/**
|
||||
* Test if loopbacks work as expected.
|
||||
*
|
||||
* A loopback is when WordPress queries itself, for example to start a new WP_Cron instance, or when editing a
|
||||
* plugin or theme. This has shown itself to be a recurring issue as code can very easily break this interaction.
|
||||
* A loopback is when WordPress queries itself, for example to start a new WP_Cron instance,
|
||||
* or when editing a plugin or theme. This has shown itself to be a recurring issue,
|
||||
* as code can very easily break this interaction.
|
||||
*
|
||||
* @since 5.2.0
|
||||
*
|
||||
|
@ -2063,7 +2067,7 @@ class WP_Site_Health {
|
|||
*
|
||||
* @param array $test_type {
|
||||
* An associative array, where the `$test_type` is either `direct` or
|
||||
* `async`, to declare if the test should run via AJAX calls after page load.
|
||||
* `async`, to declare if the test should run via Ajax calls after page load.
|
||||
*
|
||||
* @type array $identifier {
|
||||
* `$identifier` should be a unique identifier for the test that should run.
|
||||
|
@ -2071,7 +2075,7 @@ class WP_Site_Health {
|
|||
* to avoid any collisions between tests.
|
||||
*
|
||||
* @type string $label A friendly label for your test to identify it by.
|
||||
* @type mixed $test A callable to perform a direct test, or a string AJAX action to be called
|
||||
* @type mixed $test A callable to perform a direct test, or a string Ajax action to be called
|
||||
* to perform an async test.
|
||||
* }
|
||||
* }
|
||||
|
@ -2148,8 +2152,9 @@ class WP_Site_Health {
|
|||
/**
|
||||
* Check if any scheduled tasks have been missed.
|
||||
*
|
||||
* Returns a boolean value of `true` if a scheduled task has been missed and ends processing. If the list of
|
||||
* crons is an instance of WP_Error, return the instance instead of a boolean value.
|
||||
* Returns a boolean value of `true` if a scheduled task has been missed and ends processing.
|
||||
*
|
||||
* If the list of crons is an instance of WP_Error, return the instance instead of a boolean value.
|
||||
*
|
||||
* @since 5.2.0
|
||||
*
|
||||
|
@ -2173,8 +2178,9 @@ class WP_Site_Health {
|
|||
/**
|
||||
* Check if any scheduled tasks are late.
|
||||
*
|
||||
* Returns a boolean value of `true` if a scheduled task is late and ends processing. If the list of
|
||||
* crons is an instance of WP_Error, return the instance instead of a boolean value.
|
||||
* Returns a boolean value of `true` if a scheduled task is late and ends processing.
|
||||
*
|
||||
* If the list of crons is an instance of WP_Error, return the instance instead of a boolean value.
|
||||
*
|
||||
* @since 5.3.0
|
||||
*
|
||||
|
|
|
@ -536,7 +536,7 @@ function wp_comment_trashnotice() {
|
|||
<div class="hidden" id="trash-undo-holder">
|
||||
<div class="trash-undo-inside">
|
||||
<?php
|
||||
/* translators: %s: Comment author, filled by AJAX. */
|
||||
/* translators: %s: Comment author, filled by Ajax. */
|
||||
printf( __( 'Comment by %s moved to the Trash.' ), '<strong></strong>' );
|
||||
?>
|
||||
<span class="undo untrash"><a href="#"><?php _e( 'Undo' ); ?></a></span>
|
||||
|
@ -545,7 +545,7 @@ function wp_comment_trashnotice() {
|
|||
<div class="hidden" id="spam-undo-holder">
|
||||
<div class="spam-undo-inside">
|
||||
<?php
|
||||
/* translators: %s: Comment author, filled by AJAX. */
|
||||
/* translators: %s: Comment author, filled by Ajax. */
|
||||
printf( __( 'Comment by %s marked as spam.' ), '<strong></strong>' );
|
||||
?>
|
||||
<span class="undo unspam"><a href="#"><?php _e( 'Undo' ); ?></a></span>
|
||||
|
|
|
@ -127,7 +127,7 @@
|
|||
// Grab the selected attachment.
|
||||
var attachment = frame.state().get('selection').first();
|
||||
|
||||
// Run an AJAX request to set the background image.
|
||||
// Run an Ajax request to set the background image.
|
||||
$.post( ajaxurl, {
|
||||
action: 'set-background-image',
|
||||
attachment_id: attachment.id,
|
||||
|
|
|
@ -4440,7 +4440,7 @@
|
|||
|
||||
/**
|
||||
* Callback handler for when an attachment is selected in the media modal.
|
||||
* Does an additional AJAX request for setting the background context.
|
||||
* Does an additional Ajax request for setting the background context.
|
||||
*/
|
||||
select: function() {
|
||||
api.UploadControl.prototype.select.apply( this, arguments );
|
||||
|
|
|
@ -64,7 +64,7 @@ jQuery(document).ready( function($) {
|
|||
window.ajaxWidgets = ['dashboard_primary'];
|
||||
|
||||
/**
|
||||
* Triggers widget updates via AJAX.
|
||||
* Triggers widget updates via Ajax.
|
||||
*
|
||||
* @since 2.7.0
|
||||
*
|
||||
|
@ -103,7 +103,7 @@ jQuery(document).ready( function($) {
|
|||
// If we have received a specific element to fetch, check if it is valid.
|
||||
if ( el ) {
|
||||
el = el.toString();
|
||||
// If the element is available as AJAX widget, show it.
|
||||
// If the element is available as Ajax widget, show it.
|
||||
if ( $.inArray(el, ajaxWidgets) !== -1 ) {
|
||||
// Show element without any delay.
|
||||
show(0, el);
|
||||
|
|
|
@ -385,7 +385,7 @@ window.wp = window.wp || {};
|
|||
|
||||
/**
|
||||
* Saves the changes made in the quick edit window to the post.
|
||||
* AJAX saving is only for Quick Edit and not for bulk edit.
|
||||
* Ajax saving is only for Quick Edit and not for bulk edit.
|
||||
*
|
||||
* @since 2.7.0
|
||||
*
|
||||
|
|
|
@ -23,7 +23,7 @@ jQuery(function($) {
|
|||
img_size = $( 'input[name="attachments[' + id + '][image-size]"]:checked').val();
|
||||
|
||||
/**
|
||||
* This AJAX action has been deprecated since 3.5.0, see custom-background.php
|
||||
* This Ajax action has been deprecated since 3.5.0, see custom-background.php
|
||||
*/
|
||||
jQuery.post(ajaxurl, {
|
||||
action: 'set-background-image',
|
||||
|
|
|
@ -920,7 +920,7 @@
|
|||
q = input.val();
|
||||
|
||||
/*
|
||||
* Minimum characters for a search. Also avoid a new AJAX search when
|
||||
* Minimum characters for a search. Also avoid a new Ajax search when
|
||||
* the pressed key (e.g. arrows) doesn't change the searched term.
|
||||
*/
|
||||
if ( q.length < minSearchLength || api.lastSearch == q ) {
|
||||
|
|
|
@ -150,7 +150,7 @@ jQuery( document ).ready( function( $ ) {
|
|||
|
||||
/*
|
||||
* Open the Plugin details modal. The event is delegated to get also the links
|
||||
* in the plugins search tab, after the AJAX search rebuilds the HTML. It's
|
||||
* in the plugins search tab, after the Ajax search rebuilds the HTML. It's
|
||||
* delegated on the closest ancestor and not on the body to avoid conflicts
|
||||
* with other handlers, see Trac ticket #43082.
|
||||
*/
|
||||
|
|
|
@ -29,7 +29,7 @@ window.wp = window.wp || {};
|
|||
st : 0,
|
||||
|
||||
/**
|
||||
* Fetch comments using AJAX and display them in the box.
|
||||
* Fetch comments using Ajax and display them in the box.
|
||||
*
|
||||
* @memberof commentsBox
|
||||
*
|
||||
|
@ -938,7 +938,7 @@ jQuery(document).ready( function($) {
|
|||
|
||||
/**
|
||||
* Handle the editing of the post_name. Create the required HTML elements and
|
||||
* update the changes via AJAX.
|
||||
* update the changes via Ajax.
|
||||
*
|
||||
* @global
|
||||
*
|
||||
|
|
|
@ -284,8 +284,8 @@
|
|||
*
|
||||
* @since 2.9.0
|
||||
*
|
||||
* @param {number|string} r The response message from the AJAX call.
|
||||
* @param {string} stat The status of the AJAX request.
|
||||
* @param {number|string} r The response message from the Ajax call.
|
||||
* @param {string} stat The status of the Ajax request.
|
||||
*
|
||||
* @return {void}
|
||||
*/
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
* @param {jQuery} $ jQuery object.
|
||||
* @param {object} wp WP object.
|
||||
* @param {object} settings WP Updates settings.
|
||||
* @param {string} settings.ajax_nonce AJAX nonce.
|
||||
* @param {string} settings.ajax_nonce Ajax nonce.
|
||||
* @param {object=} settings.plugins Base names of plugins in their different states.
|
||||
* @param {Array} settings.plugins.all Base names of all plugins.
|
||||
* @param {Array} settings.plugins.active Base names of active plugins.
|
||||
|
@ -1531,9 +1531,9 @@
|
|||
* @since 4.6.0
|
||||
* @private
|
||||
*
|
||||
* @param {object} data AJAX payload.
|
||||
* @param {object} data Ajax payload.
|
||||
* @param {string} action The type of request to perform.
|
||||
* @return {object} The AJAX payload with the appropriate callbacks.
|
||||
* @return {object} The Ajax payload with the appropriate callbacks.
|
||||
*/
|
||||
wp.updates._addCallbacks = function( data, action ) {
|
||||
if ( 'import' === pagenow && 'install-plugin' === action ) {
|
||||
|
@ -1769,7 +1769,7 @@
|
|||
};
|
||||
|
||||
/**
|
||||
* Validates an AJAX response to ensure it's a proper object.
|
||||
* Validates an Ajax response to ensure it's a proper object.
|
||||
*
|
||||
* If the response deems to be invalid, an admin notice is being displayed.
|
||||
*
|
||||
|
|
|
@ -3575,7 +3575,7 @@ function _default_wp_die_handler( $message, $title = '', $args = array() ) {
|
|||
* @param string|array $args Optional. Arguments to control behavior. Default empty array.
|
||||
*/
|
||||
function _ajax_wp_die_handler( $message, $title = '', $args = array() ) {
|
||||
// Set default 'response' to 200 for AJAX requests.
|
||||
// Set default 'response' to 200 for Ajax requests.
|
||||
$args = wp_parse_args(
|
||||
$args,
|
||||
array( 'response' => 200 )
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
* wp.customize.HeaderTool.ImageModel
|
||||
*
|
||||
* A header image. This is where saves via the Customizer API are
|
||||
* abstracted away, plus our own AJAX calls to add images to and remove
|
||||
* abstracted away, plus our own Ajax calls to add images to and remove
|
||||
* images from the user's recently uploaded images setting on the server.
|
||||
* These calls are made regardless of whether the user actually saves new
|
||||
* Customizer settings.
|
||||
|
|
|
@ -68,7 +68,7 @@
|
|||
// Used when the interval is reset.
|
||||
originalInterval: 0,
|
||||
|
||||
// Used to limit the number of AJAX requests.
|
||||
// Used to limit the number of Ajax requests.
|
||||
minimalInterval: 0,
|
||||
|
||||
// Used together with tempInterval.
|
||||
|
@ -146,7 +146,7 @@
|
|||
}
|
||||
|
||||
/*
|
||||
* Used to limit the number of AJAX requests. Overrides all other intervals
|
||||
* Used to limit the number of Ajax requests. Overrides all other intervals
|
||||
* if they are shorter. Needed for some hosts that cannot handle frequent requests
|
||||
* and the user may exceed the allocated server CPU time, etc. The minimal interval
|
||||
* can be up to 600 seconds, however setting it to longer than 120 seconds
|
||||
|
|
|
@ -882,7 +882,7 @@ var Attachments = Backbone.Collection.extend(/** @lends wp.media.model.Attachmen
|
|||
return this.mirroring ? this.mirroring.hasMore() : false;
|
||||
},
|
||||
/**
|
||||
* A custom AJAX-response parser.
|
||||
* A custom Ajax-response parser.
|
||||
*
|
||||
* See trac ticket #24753
|
||||
*
|
||||
|
|
|
@ -148,7 +148,7 @@ function prepareMediaItemInit( fileObj ) {
|
|||
// Replace the original filename with the new (unique) one assigned during upload.
|
||||
jQuery( '.filename.original', item ).replaceWith( jQuery( '.filename.new', item ) );
|
||||
|
||||
// Bind AJAX to the new Delete button.
|
||||
// Bind Ajax to the new Delete button.
|
||||
jQuery( 'a.delete', item ).click( function(){
|
||||
// Tell the server to delete it. TODO: Handle exceptions.
|
||||
jQuery.ajax({
|
||||
|
@ -166,7 +166,7 @@ function prepareMediaItemInit( fileObj ) {
|
|||
return false;
|
||||
});
|
||||
|
||||
// Bind AJAX to the new Undo button.
|
||||
// Bind Ajax to the new Undo button.
|
||||
jQuery( 'a.undo', item ).click( function(){
|
||||
// Tell the server to untrash it. TODO: Handle exceptions.
|
||||
jQuery.ajax({
|
||||
|
|
|
@ -294,7 +294,7 @@ wpList = {
|
|||
},
|
||||
|
||||
/**
|
||||
* Adds an item to the list via AJAX.
|
||||
* Adds an item to the list via Ajax.
|
||||
*
|
||||
* @param {HTMLElement} element The DOM element.
|
||||
* @param {object} settings Settings for this list.
|
||||
|
@ -396,7 +396,7 @@ wpList = {
|
|||
},
|
||||
|
||||
/**
|
||||
* Delete an item in the list via AJAX.
|
||||
* Delete an item in the list via Ajax.
|
||||
*
|
||||
* @param {HTMLElement} element A DOM element containing item data.
|
||||
* @param {object} settings Settings for this list.
|
||||
|
@ -483,7 +483,7 @@ wpList = {
|
|||
},
|
||||
|
||||
/**
|
||||
* Dim an item in the list via AJAX.
|
||||
* Dim an item in the list via Ajax.
|
||||
*
|
||||
* @param {HTMLElement} element A DOM element containing item data.
|
||||
* @param {object} settings Settings for this list.
|
||||
|
|
|
@ -891,7 +891,7 @@ function is_protected_endpoint() {
|
|||
return true;
|
||||
}
|
||||
|
||||
// Protect AJAX actions that could help resolve a fatal error should be available.
|
||||
// Protect Ajax actions that could help resolve a fatal error should be available.
|
||||
if ( is_protected_ajax_action() ) {
|
||||
return true;
|
||||
}
|
||||
|
@ -901,21 +901,22 @@ function is_protected_endpoint() {
|
|||
*
|
||||
* This filter is only fired when an endpoint is requested which is not already protected by
|
||||
* WordPress core. As such, it exclusively allows providing further protected endpoints in
|
||||
* addition to the admin backend, login pages and protected AJAX actions.
|
||||
* addition to the admin backend, login pages and protected Ajax actions.
|
||||
*
|
||||
* @since 5.2.0
|
||||
*
|
||||
* @param bool $is_protected_endpoint Whether the currently requested endpoint is protected. Default false.
|
||||
* @param bool $is_protected_endpoint Whether the currently requested endpoint is protected.
|
||||
* Default false.
|
||||
*/
|
||||
return (bool) apply_filters( 'is_protected_endpoint', false );
|
||||
}
|
||||
|
||||
/**
|
||||
* Determines whether we are currently handling an AJAX action that should be protected against WSODs.
|
||||
* Determines whether we are currently handling an Ajax action that should be protected against WSODs.
|
||||
*
|
||||
* @since 5.2.0
|
||||
*
|
||||
* @return bool True if the current AJAX action should be protected.
|
||||
* @return bool True if the current Ajax action should be protected.
|
||||
*/
|
||||
function is_protected_ajax_action() {
|
||||
if ( ! wp_doing_ajax() ) {
|
||||
|
@ -938,13 +939,13 @@ function is_protected_ajax_action() {
|
|||
);
|
||||
|
||||
/**
|
||||
* Filters the array of protected AJAX actions.
|
||||
* Filters the array of protected Ajax actions.
|
||||
*
|
||||
* This filter is only fired when doing AJAX and the AJAX request has an 'action' property.
|
||||
* This filter is only fired when doing Ajax and the Ajax request has an 'action' property.
|
||||
*
|
||||
* @since 5.2.0
|
||||
*
|
||||
* @param string[] $actions_to_protect Array of strings with AJAX actions to protect.
|
||||
* @param string[] $actions_to_protect Array of strings with Ajax actions to protect.
|
||||
*/
|
||||
$actions_to_protect = (array) apply_filters( 'wp_protected_ajax_actions', $actions_to_protect );
|
||||
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '5.5-alpha-48167';
|
||||
$wp_version = '5.5-alpha-48168';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
|
Loading…
Reference in New Issue