From 25c0710f4cb735a62df997273fb9f9d497b61044 Mon Sep 17 00:00:00 2001 From: Drew Jaynes Date: Mon, 12 Oct 2015 16:10:44 +0000 Subject: [PATCH] Docs: Fix syntax and properly mark optional parameters as such in the DocBlock for `get_image_send_to_editor()`. Also fixes the return description, and adds the `$size` default value, missed in [35055]. See #34257. See #32246. git-svn-id: https://develop.svn.wordpress.org/trunk@35056 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/media.php | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/src/wp-admin/includes/media.php b/src/wp-admin/includes/media.php index e259766d8b..8181ba5ad0 100644 --- a/src/wp-admin/includes/media.php +++ b/src/wp-admin/includes/media.php @@ -106,17 +106,18 @@ function the_media_upload_tabs() { * * @since 2.5.0 * - * @param int $id image attachment id - * @param string $caption image caption - * @param string $title image title attribute - * @param string $align image css alignment property - * @param string $url image src url - * @param string $rel image rel attribute + * @param int $id Image attachment id. + * @param string $caption Image caption. + * @param string $title Image title attribute. + * @param string $align Image CSS alignment property. + * @param string $url Optional. Image src URL. Default empty. + * @param string $rel Optional. Image rel attribute. Default empty. * @param string|array $size Optional. Image size. Accepts any valid image size, or an array of width - * and height values in pixels (in that order). - * @return string the html to insert into editor + * and height values in pixels (in that order). Default 'medium'. + * @param string $alt Optional. Image alt attribute. Default empty. + * @return string The HTML output to insert into the editor. */ -function get_image_send_to_editor( $id, $caption, $title, $align, $url='', $rel = '', $size='medium', $alt = '' ) { +function get_image_send_to_editor( $id, $caption, $title, $align, $url = '', $rel = '', $size = 'medium', $alt = '' ) { $html = get_image_tag($id, $alt, '', $align, $size);