Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: load-{$page_hook}

To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).

Understanding Source Code

The best way to understand what a hook does is to look at where it occurs in the source code.

Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.

Source View

Line Code
228            * 3. The plugin basename minus the file extension.
229            *
230            * Together, the three parts form the `$page_hook`. Citing the example above,
231            * the hook name used would be 'load-settings_page_pluginbasename'.
232            *
233            * @see get_plugin_page_hook()
234            *
235            * @since 2.1.0
236            */
237           do_action( "load-{$page_hook}" ); // phpcs:ignore WordPress.NamingConventions.ValidHookName.UseUnderscores
238           if ( ! isset( $_GET['noheader'] ) ) {
239                require_once ABSPATH . 'wp-admin/admin-header.php';
240           }
241
242           /**
243            * Used to call the registered callback for a plugin screen.
244            *
245            * This hook uses a dynamic hook name, `$page_hook`, which refers to a mixture of plugin
246            * page information including: