Make WordPress Core

Opened 18 hours ago

Closed 12 hours ago

#64790 closed defect (bug) (fixed)

Connectors: Register as a dedicated admin page instead of a virtual submenu page

Reported by: gziolo's profile gziolo Owned by: jorgefilipecosta's profile jorgefilipecosta
Milestone: 7.0 Priority: normal
Severity: normal Version: trunk
Component: Menus Keywords:
Focuses: Cc:

Description (last modified by gziolo)

The Connectors settings screen is currently registered as a virtual submenu page under Settings, accessible at wp-admin/options-general.php?page=connectors-wp-admin. It should be changed to a dedicated options page with its own URL (e.g., options-connectors.php), consistent with how other core settings pages are structured.

## Description

The Connectors screen was introduced in [Gutenberg#75833](https://github.com/WordPress/gutenberg/pull/75833) and further iterated on in [Gutenberg#76014](https://github.com/WordPress/gutenberg/pull/76014). During review, multiple contributors recommended moving away from the virtual submenu page pattern toward a real options page.

### Current behavior

The page is registered using add_submenu_page() under options-general.php, resulting in a URL like:

wp-admin/options-general.php?page=connectors-wp-admin

### Expected behavior

The page should be a first-class core settings page with a dedicated URL, for example:

wp-admin/options-connectors.php

This is how all other core settings pages are structured: options-general.php, options-writing.php, options-reading.php, options-discussion.php, options-media.php, options-privacy.php, and options-permalink.php.

### Reasons for the change

  • Consistency with core patterns. Every existing core settings page under the Settings menu has its own options-*.php URL. Virtual submenu pages using query parameters (?page=...) are the pattern for plugin-added settings pages, not core screens.
  • Clean URL for linking and redirects. A dedicated URL is easier for other code to reference, redirect to, or use in capability checks and admin notices.
  • Long-term stability. As a core settings page that plugins and documentation will link to, a stable, short URL avoids churn and makes the feature feel intentional rather than bolted on.

Change History (2)

#1 @gziolo
18 hours ago

  • Description modified (diff)
  • Owner set to jorgefilipecosta
  • Status changed from new to assigned

#2 @gziolo
12 hours ago

  • Resolution set to fixed
  • Status changed from assigned to closed

In 61825:

Connectors: Change admin URL to options-connectors.php.

Changes the Connectors screen URL from a query parameter page to a direct file, following the Settings menu naming convention used by other settings pages (options-general.php, options-writing.php, etc.).

  • Adds src/wp-admin/options-connectors.php as a direct admin screen file.
  • Adds a static submenu entry in menu.php at position 12 (after General).
  • Removes _wp_connectors_add_settings_menu_item() and its admin_menu hook from connectors.php.
  • Updates the script_module_data filter from connectors-wp-admin to options-connectors-wp-admin.

Synced from https://github.com/WordPress/gutenberg/pull/76142.
Developed in https://github.com/WordPress/wordpress-develop/pull/11157.

Follow-up to [61749], [61824].
See #64730.

Props jorgefilipecosta, gziolo.
Fixes #64790.

Note: See TracTickets for help on using tickets.