WordPress at a glance

get_current_screen() WP 1.0

Get the current screen object

  • Global. WP_Screen. $current_screen
Is the basis for: add_screen_option()
Works based on: WP_Screen()
✈ 1 time = 0.000016s = very fast | 50000 times = 0.01s = speed of light

No Hooks.


WP_Screen/null. Current screen object or null when screen not defined.



Code of get current screen: wp-admin/includes/screen.php VER 5.0.3

function get_current_screen() {
	global $current_screen;

	if ( ! isset( $current_screen ) )
		return null;

	return $current_screen;

Related Functions

From category: Admin Menu

No comments
    Hello, !     Log In . Register