Skip to content

Editor: Update Site Editor URL in Welcome widget to use new path-based format #8514

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 6 commits into
base: trunk
Choose a base branch
from
2 changes: 1 addition & 1 deletion src/wp-admin/includes/dashboard.php
Original file line number Diff line number Diff line change
Expand Up @@ -2115,7 +2115,7 @@ function wp_welcome_panel() {
<?php if ( $is_block_theme ) : ?>
<h3><?php _e( 'Switch up your site&#8217;s look & feel with Styles' ); ?></h3>
<p><?php _e( 'Tweak your site, or give it a whole new look! Get creative &#8212; how about a new color palette or font?' ); ?></p>
<a href="<?php echo esc_url( admin_url( '/site-editor.php?path=%2Fwp_global_styles' ) ); ?>"><?php _e( 'Edit styles' ); ?></a>
<a href="<?php echo esc_url( admin_url( '/site-editor.php?p=%2Fstyles' ) ); ?>"><?php _e( 'Edit styles' ); ?></a>
<?php else : ?>
<h3><?php _e( 'Discover a new way to build your site.' ); ?></h3>
<p><?php _e( 'There is a new kind of WordPress theme, called a block theme, that lets you build the site you&#8217;ve always wanted &#8212; with blocks and styles.' ); ?></p>
Expand Down
10 changes: 4 additions & 6 deletions src/wp-includes/post.php
Original file line number Diff line number Diff line change
Expand Up @@ -338,9 +338,8 @@ function create_initial_post_types() {

$template_edit_link = 'site-editor.php?' . build_query(
array(
'postType' => '%s',
'postId' => '%s',
'canvas' => 'edit',
'p' => '/%s/%s',
'canvas' => 'edit',
)
);

Expand Down Expand Up @@ -510,9 +509,8 @@ function create_initial_post_types() {

$navigation_post_edit_link = 'site-editor.php?' . build_query(
array(
'postId' => '%s',
'postType' => 'wp_navigation',
'canvas' => 'edit',
'p' => '/wp_navigation/%s',
'canvas' => 'edit',
)
);

Expand Down
Loading