Skip to content
Permalink
Browse files

Block Editor: Fix the link to the classic editor when incompatible me…

…ta boxen are detected.

Props tmatsuur, mukesh27.
Merges [45618] to the 5.2 branch.
Fixes #45935.

git-svn-id: https://develop.svn.wordpress.org/branches/5.2@45848 602fd350-edb4-49c9-b593-d223f7449a82
  • Loading branch information...
SergeyBiryukov committed Aug 19, 2019
1 parent e4d806c commit 6db50b05348e3a28682868d2bfe30e93cb021bfb
Showing with 7 additions and 1 deletion.
  1. +7 −1 src/wp-admin/includes/template.php
@@ -1122,7 +1122,13 @@ function do_block_editor_incompatible_meta_box( $object, $box ) {
echo '</p>';
}
} elseif ( $object instanceof WP_Post ) {
$edit_url = add_query_arg( 'classic-editor', '', get_edit_post_link( $object ) );
$edit_url = add_query_arg(
array(
'classic-editor' => '',
'classic-editor__forget' => '',
),
get_edit_post_link( $object )
);
echo '<p>';
/* translators: %s: A link to use the Classic Editor plugin. */
printf( __( 'Please open the <a href="%s">classic editor</a> to use this meta box.' ), esc_url( $edit_url ) );

0 comments on commit 6db50b0

Please sign in to comment.
You can’t perform that action at this time.