From 53c00249450eddedf0abc87934783bf423db2f82 Mon Sep 17 00:00:00 2001 From: Ryan Boren Date: Mon, 5 Nov 2012 14:33:56 +0000 Subject: [PATCH] Use wp_basename() instead of basename() so that multibyte characters are not stomped. Props SergeyBiryukov. fixes #21217 git-svn-id: http://core.svn.wordpress.org/trunk@22367 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-admin/includes/media.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wp-admin/includes/media.php b/wp-admin/includes/media.php index 0adf06d50d..e58725d585 100644 --- a/wp-admin/includes/media.php +++ b/wp-admin/includes/media.php @@ -1072,7 +1072,7 @@ function get_media_item( $attachment_id, $args = null ) { $toggle_on = __( 'Show' ); $toggle_off = __( 'Hide' ); - $filename = esc_html( basename( $post->guid ) ); + $filename = esc_html( wp_basename( $post->guid ) ); $title = esc_attr( $post->post_title ); if ( $_tags = get_the_tags( $attachment_id ) ) {