. * * ███████╗███████╗██████╗ ██╗ ██╗███╗ ███╗ █████╗ ███████╗██╗ ██╗ * ██╔════╝██╔════╝██╔══██╗██║ ██║████╗ ████║██╔══██╗██╔════╝██║ ██╔╝ * ███████╗█████╗ ██████╔╝██║ ██║██╔████╔██║███████║███████╗█████╔╝ * ╚════██║██╔══╝ ██╔══██╗╚██╗ ██╔╝██║╚██╔╝██║██╔══██║╚════██║██╔═██╗ * ███████║███████╗██║ ██║ ╚████╔╝ ██║ ╚═╝ ██║██║ ██║███████║██║ ██╗ * ╚══════╝╚══════╝╚═╝ ╚═╝ ╚═══╝ ╚═╝ ╚═╝╚═╝ ╚═╝╚══════╝╚═╝ ╚═╝ */ class Ai1wm_Status_Controller { public static function status( $params = array() ) { // Set params if ( empty( $params ) ) { $params = stripslashes_deep( $_GET ); } // Set secret key $secret_key = null; if ( isset( $params['secret_key'] ) ) { $secret_key = trim( $params['secret_key'] ); } try { // Ensure that unauthorized people cannot access status action ai1wm_verify_secret_key( $secret_key ); } catch ( Ai1wm_Not_Valid_Secret_Key_Exception $e ) { exit; } echo json_encode( get_option( AI1WM_STATUS, array() ) ); exit; } }