WordPress at Your Fingertips
function is not described

WC_Admin_API_Keys::page_output() public WC 1.0

Page output.

{} It's a method of the class: WC_Admin_API_Keys{}

No Hooks.

Return

null. Nothing.

Usage

$result = WC_Admin_API_Keys::page_output();

Code of WC_Admin_API_Keys::page_output() WC 5.9.0

public static function page_output() {
	// Hide the save button.
	$GLOBALS['hide_save_button'] = true;

	if ( isset( $_GET['create-key'] ) || isset( $_GET['edit-key'] ) ) {
		$key_id   = isset( $_GET['edit-key'] ) ? absint( $_GET['edit-key'] ) : 0; // WPCS: input var okay, CSRF ok.
		$key_data = self::get_key_data( $key_id );
		$user_id  = (int) $key_data['user_id'];

		if ( $key_id && $user_id && ! current_user_can( 'edit_user', $user_id ) ) {
			if ( get_current_user_id() !== $user_id ) {
				wp_die( esc_html__( 'You do not have permission to edit this API Key', 'woocommerce' ) );
			}
		}

		include dirname( __FILE__ ) . '/settings/views/html-keys-edit.php';
	} else {
		self::table_list_output();
	}
}