wpseek.com
A WordPress-centric search engine for devs and theme authors



register_font_library_wp_admin_route › WordPress Function

Sincen/a
Deprecatedn/a
register_font_library_wp_admin_route ( $path, $content_module = null, $route_module = null )
Parameters: (3)
  • (string) $path Route path (e.g., '/types/$type/edit/$id').
    Required: Yes
  • (string|null) $content_module Script module ID for content (stage/inspector).
    Required: No
    Default: null
  • (string|null) $route_module Script module ID for route lifecycle hooks.
    Required: No
    Default: null
Defined at:
Codex:

Register a route for the font-library-wp-admin page.



Source

function register_font_library_wp_admin_route( $path, $content_module = null, $route_module = null ) {
		global $wp_font_library_wp_admin_routes;

		$route = array( 'path' => $path );
		if ( ! empty( $content_module ) ) {
			$route['content_module'] = $content_module;
		}
		if ( ! empty( $route_module ) ) {
			$route['route_module'] = $route_module;
		}

		$wp_font_library_wp_admin_routes[] = $route;
	}
}