From c5ef3b79767f4df5cb4ddb9212a1eefd4cdd51f9 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Tue, 28 Jul 2020 21:21:05 +0000 Subject: [PATCH] Media: Pass the `$rel` parameter to `image_send_to_editor` filter. Props mihdan, pputzer. Fixes #50765. Built from https://develop.svn.wordpress.org/trunk@48684 git-svn-id: http://core.svn.wordpress.org/trunk@48446 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-admin/includes/media.php | 4 +++- wp-includes/version.php | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/wp-admin/includes/media.php b/wp-admin/includes/media.php index 3daa4a2ad1..d206aa163c 100644 --- a/wp-admin/includes/media.php +++ b/wp-admin/includes/media.php @@ -152,6 +152,7 @@ function get_image_send_to_editor( $id, $caption, $title, $align, $url = '', $re * Filters the image HTML markup to send to the editor when inserting an image. * * @since 2.5.0 + * @since 5.6.0 The `$rel` parameter was added. * * @param string $html The image HTML markup to send. * @param int $id The attachment ID. @@ -162,8 +163,9 @@ function get_image_send_to_editor( $id, $caption, $title, $align, $url = '', $re * @param string|array $size Size of image. Image size or array of width and height values * (in that order). Default 'medium'. * @param string $alt The image alternative, or alt, text. + * @param string $rel The image rel attribute. */ - $html = apply_filters( 'image_send_to_editor', $html, $id, $caption, $title, $align, $url, $size, $alt ); + $html = apply_filters( 'image_send_to_editor', $html, $id, $caption, $title, $align, $url, $size, $alt, $rel ); return $html; } diff --git a/wp-includes/version.php b/wp-includes/version.php index 04e543b6eb..543d958f28 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -13,7 +13,7 @@ * * @global string $wp_version */ -$wp_version = '5.6-alpha-48683'; +$wp_version = '5.6-alpha-48684'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.