WordPress.org

Make WordPress Core

Changeset 14901


Ignore:
Timestamp:
05/25/2010 06:55:51 PM (8 years ago)
Author:
nacin
Message:

Use a post type object label for edit_post_link's title attribute. props sc0ttkclark.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/link-template.php

    r14711 r14901  
    828828        $link = __('Edit This');
    829829
    830     $link = '<a class="post-edit-link" href="' . $url . '" title="' . esc_attr( __( 'Edit Post' ) ) . '">' . $link . '</a>';
     830    $post_type_obj = get_post_type_object( $post->post_type );
     831    $link = '<a class="post-edit-link" href="' . $url . '" title="' . esc_attr( $post_type_obj->labels->edit_item ) . '">' . $link . '</a>';
    831832    echo $before . apply_filters( 'edit_post_link', $link, $post->ID ) . $after;
    832833}
Note: See TracChangeset for help on using the changeset viewer.