PageController::get_current_screen_id()

Returns the current screen ID.


Description Description

This is slightly different from WP’s get_current_screen, in that it attaches an action, so certain pages like ‘add new’ pages can have different breadcrumbs or handling. It also catches some more unique dynamic pages like taxonomy/attribute management.

Format:

  • {$current_screen->action}-{$current_screen->action}-tab-section
  • {$current_screen->action}-{$current_screen->action}-tab
  • {$current_screen->action}-{$current_screen->action} if no tab is present
  • {$current_screen->action} if no action or tab is present

Return Return

(string) Current screen ID.


Top ↑

Source Source

File: packages/woocommerce-admin/src/PageController.php


			


Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.