114 $time_format = __( 'g:i a' ); |
114 $time_format = __( 'g:i a' ); |
115 |
115 |
116 wp_enqueue_script( 'common' ); |
116 wp_enqueue_script( 'common' ); |
117 |
117 |
118 /** |
118 /** |
119 * $pagenow is set in vars.php |
119 * $pagenow is set in vars.php. |
120 * $wp_importers is sometimes set in wp-admin/includes/import.php |
120 * $wp_importers is sometimes set in wp-admin/includes/import.php. |
121 * The remaining variables are imported as globals elsewhere, declared as globals here |
121 * The remaining variables are imported as globals elsewhere, declared as globals here. |
122 * |
122 * |
123 * @global string $pagenow |
123 * @global string $pagenow The filename of the current screen. |
124 * @global array $wp_importers |
124 * @global array $wp_importers |
125 * @global string $hook_suffix |
125 * @global string $hook_suffix |
126 * @global string $plugin_page |
126 * @global string $plugin_page |
127 * @global string $typenow |
127 * @global string $typenow The post type of the current screen. |
128 * @global string $taxnow |
128 * @global string $taxnow The taxonomy of the current screen. |
129 */ |
129 */ |
130 global $pagenow, $wp_importers, $hook_suffix, $plugin_page, $typenow, $taxnow; |
130 global $pagenow, $wp_importers, $hook_suffix, $plugin_page, $typenow, $taxnow; |
131 |
131 |
132 $page_hook = null; |
132 $page_hook = null; |
133 |
133 |
318 /** |
318 /** |
319 * Fires before an importer screen is loaded. |
319 * Fires before an importer screen is loaded. |
320 * |
320 * |
321 * The dynamic portion of the hook name, `$importer`, refers to the importer slug. |
321 * The dynamic portion of the hook name, `$importer`, refers to the importer slug. |
322 * |
322 * |
|
323 * Possible hook names include: |
|
324 * |
|
325 * - `load-importer-blogger` |
|
326 * - `load-importer-wpcat2tag` |
|
327 * - `load-importer-livejournal` |
|
328 * - `load-importer-mt` |
|
329 * - `load-importer-rss` |
|
330 * - `load-importer-tumblr` |
|
331 * - `load-importer-wordpress` |
|
332 * |
323 * @since 3.5.0 |
333 * @since 3.5.0 |
324 */ |
334 */ |
325 do_action( "load-importer-{$importer}" ); // phpcs:ignore WordPress.NamingConventions.ValidHookName.UseUnderscores |
335 do_action( "load-importer-{$importer}" ); // phpcs:ignore WordPress.NamingConventions.ValidHookName.UseUnderscores |
326 |
336 |
|
337 // Used in the HTML title tag. |
|
338 $title = __( 'Import' ); |
327 $parent_file = 'tools.php'; |
339 $parent_file = 'tools.php'; |
328 $submenu_file = 'import.php'; |
340 $submenu_file = 'import.php'; |
329 $title = __( 'Import' ); |
|
330 |
341 |
331 if ( ! isset( $_GET['noheader'] ) ) { |
342 if ( ! isset( $_GET['noheader'] ) ) { |
332 require_once ABSPATH . 'wp-admin/admin-header.php'; |
343 require_once ABSPATH . 'wp-admin/admin-header.php'; |
333 } |
344 } |
334 |
345 |
363 * Fires before a particular screen is loaded. |
374 * Fires before a particular screen is loaded. |
364 * |
375 * |
365 * The load-* hook fires in a number of contexts. This hook is for core screens. |
376 * The load-* hook fires in a number of contexts. This hook is for core screens. |
366 * |
377 * |
367 * The dynamic portion of the hook name, `$pagenow`, is a global variable |
378 * The dynamic portion of the hook name, `$pagenow`, is a global variable |
368 * referring to the filename of the current page, such as 'admin.php', |
379 * referring to the filename of the current screen, such as 'admin.php', |
369 * 'post-new.php' etc. A complete hook for the latter would be |
380 * 'post-new.php' etc. A complete hook for the latter would be |
370 * 'load-post-new.php'. |
381 * 'load-post-new.php'. |
371 * |
382 * |
372 * @since 2.1.0 |
383 * @since 2.1.0 |
373 */ |
384 */ |