diff --git a/wp-includes/functions.php b/wp-includes/functions.php index f6d3bf3137..29ce24d44d 100644 --- a/wp-includes/functions.php +++ b/wp-includes/functions.php @@ -2285,8 +2285,8 @@ function wp_explain_nonce( $action ) { $trans['add']['user'] = array( __( 'Your attempt to add this user has failed.' ), false ); $trans['delete']['users'] = array( __( 'Your attempt to delete users has failed.' ), false ); $trans['bulk']['users'] = array( __( 'Your attempt to bulk modify users has failed.' ), false ); - $trans['update']['user'] = array( __( 'Your attempt to edit this user: “%s” has failed.' ), 'get_author_name' ); - $trans['update']['profile'] = array( __( 'Your attempt to modify the profile for: “%s” has failed.' ), 'get_author_name' ); + $trans['update']['user'] = array( __( 'Your attempt to edit this user: “%s” has failed.' ), 'get_the_author_meta', 'display_name' ); + $trans['update']['profile'] = array( __( 'Your attempt to modify the profile for: “%s” has failed.' ), 'get_the_author_meta', 'display_name' ); $trans['update']['options'] = array( __( 'Your attempt to edit your settings has failed.' ), false ); $trans['update']['permalink'] = array( __( 'Your attempt to change your permalink structure to: %s has failed.' ), 'use_id' ); @@ -2299,9 +2299,15 @@ function wp_explain_nonce( $action ) { if ( isset( $trans[$verb][$noun] ) ) { if ( !empty( $trans[$verb][$noun][1] ) ) { $lookup = $trans[$verb][$noun][1]; + if ( isset($trans[$verb][$noun][2]) ) + $lookup_value = $trans[$verb][$noun][2]; $object = $matches[4]; - if ( 'use_id' != $lookup ) - $object = call_user_func( $lookup, $object ); + if ( 'use_id' != $lookup ) { + if ( isset( $lookup_value ) ) + $object = call_user_func( $lookup, $lookup_value, $object ); + else + $object = call_user_func( $lookup, $object ); + } return sprintf( $trans[$verb][$noun][0], wp_specialchars($object) ); } else { return $trans[$verb][$noun][0]; diff --git a/wp-includes/general-template.php b/wp-includes/general-template.php index f02fc6e507..bad1e00dcc 100644 --- a/wp-includes/general-template.php +++ b/wp-includes/general-template.php @@ -1486,7 +1486,7 @@ function feed_links_extra( $args ) { } elseif ( is_author() ) { $author_id = intval( get_query_var('author') ); - $title = esc_attr(sprintf( $args['authortitle'], get_bloginfo('name'), $args['separator'], get_author_name( $author_id ) )); + $title = esc_attr(sprintf( $args['authortitle'], get_bloginfo('name'), $args['separator'], get_the_author_meta( 'display_name', $author_id ) )); $href = get_author_feed_link( $author_id ); } elseif ( is_search() ) { $title = esc_attr(sprintf( $args['searchtitle'], get_bloginfo('name'), $args['separator'], get_search_query() )); diff --git a/wp-includes/post-template.php b/wp-includes/post-template.php index 853b5d4731..a8855e859f 100644 --- a/wp-includes/post-template.php +++ b/wp-includes/post-template.php @@ -1241,7 +1241,7 @@ function wp_post_revision_title( $revision, $link = true ) { * @uses wp_get_post_revisions() * @uses wp_post_revision_title() * @uses get_edit_post_link() - * @uses get_author_name() + * @uses get_the_author_meta() * * @todo split into two functions (list, form-table) ? * @@ -1286,7 +1286,7 @@ function wp_list_post_revisions( $post_id = 0, $args = null ) { continue; $date = wp_post_revision_title( $revision ); - $name = get_author_name( $revision->post_author ); + $name = get_the_author_meta( 'display_name', $revision->post_author ); if ( 'form-table' == $format ) { if ( $left )