How to get specific page screen ID
I don’t think it’s possible without accessing a global. This seems to work for all pages types, by using the global $_parent_pages with the function get_plugin_page_hookname: function nackle_get_screen_id( $slug ){ global $_parent_pages; $parent = array_key_exists( $slug, $_parent_pages ) ? $_parent_pages[$slug] : ”; return get_plugin_page_hookname( $slug, $parent ); } Usage example: echo nackle_get_screen_id( ‘my-custom-page-key’ ); Edit- … Read more