WordPress action hook · part of WordPress core
check_admin_referer
A WordPress core action that 6 plugins also fire themselves, running on 10K+ sites between them.
How to use check_admin_referer
It's an action: your callback runs at that point and receives 2 arguments. Nothing needs to be returned.
Add this to your theme's functions.php or a small custom plugin:
add_action( 'check_admin_referer', function( $action, $result ) {
// Your code runs here.
}, 10, 2 );Argument names come from Animation Addons for Elementor's source. Other plugins may pass different values: check the call in the plugin you're targeting below.
This hook is fired by WordPress core too. Official reference on developer.wordpress.org →
6 plugins that fire check_admin_referer
Sorted by active installs. Each entry shows where the plugin calls the hook and what it passes.
-
Animation Addons for Elementor10,000+ installs
do_action( 'check_admin_referer', $action, $result )inc/Nonce.php:217 -
Admin SSL100+ installs
do_action( 'check_admin_referer', $action, $result )includes/https.php:303 -
Cawaii Admin90+ installs
do_action( 'check_admin_referer', $action, $result )cawaii-admin.php:416 -
PublishPress Cart: eCommerce for Digital Products, Memberships, Downloads, SubscriptionsFewer than 10 installs
do_action( 'check_admin_referer', $action, $result )includes/functions/ajax-security.php:124 -
Alharthiweb Order AlertsFewer than 10 installs
do_action( 'check_admin_referer', 'alhwoa_settings', $result )includes/class-admin.php:74 -
PageFerryFewer than 10 installs
do_action( 'check_admin_referer', 'pageferry_import_execute', $valid )includes/class-pageferry-import-admin.php:488
Need a customisation built on this hook?
Tell us what you want to change and which plugin it's for. We'll write it, test it and send it back as a small plugin.