wp_ajax_rest_nonce() WordPress Function

The wp_ajax_rest_nonce() function is used to create a nonce for a given REST action. This function is only used for RESTful requests made with the WP REST API.

wp_ajax_rest_nonce() #

Ajax handler to renew the REST API nonce.


Source

File: wp-admin/includes/ajax-actions.php

function wp_ajax_rest_nonce() {
	exit( wp_create_nonce( 'wp_rest' ) );
}


Top ↑

Changelog

Changelog
VersionDescription
5.3.0Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.

Show More