): a menu that does not exist (any more), for example from a bookmark or * the back button after deleting it, gets the message WordPress gives for such a post, instead of an editor * for a new menu. */ public static function load(): void { $id = isset($_GET['optionpage']) ? absint(wp_unslash($_GET['optionpage'])) : 0; if ($id > 0 && PageRepository::rowsById($id) !== []) { return; } wp_die( sprintf( '

%s

%s

', esc_html__('You attempted to edit a menu that does not exist. Perhaps it was deleted?', 'admin-options-pages'), esc_url(SubpageMaster::url()), esc_html__('Go to all options pages', 'admin-options-pages') ), esc_html__('Menu not found', 'admin-options-pages'), ['response' => 404] ); } public static function view() { // The React editor mounts here and gets its data from the script (see Enqueue). printf('
', esc_attr(Plugin::PREFIX) . 'root'); print('
'); print('
'); print('
'); } }