Dashboard: Use `_draft_or_post_title()` to display `(no title)` if no post title is set. see #25824.
Built from https://develop.svn.wordpress.org/trunk@26337 git-svn-id: http://core.svn.wordpress.org/trunk@26238 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
2597e857be
commit
06b4f99e18
|
@ -349,13 +349,13 @@ function wp_dashboard_quick_press( $error_msg = false ) {
|
||||||
if ( ! $drafts ) {
|
if ( ! $drafts ) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
echo '<div class="drafts">';
|
echo '<div class="drafts">';
|
||||||
if ( count( $drafts ) > 3 ) {
|
if ( count( $drafts ) > 3 ) {
|
||||||
echo '<p class="view-all"><a href="' . esc_url( admin_url( 'edit.php?post_status=draft' ) ) . '">' . _x( 'View all', 'drafts' ) . "</a></p>\n";
|
echo '<p class="view-all"><a href="' . esc_url( admin_url( 'edit.php?post_status=draft' ) ) . '">' . _x( 'View all', 'drafts' ) . "</a></p>\n";
|
||||||
}
|
}
|
||||||
echo '<h4>' . __( 'Drafts' ) . "</h4>\n<ul>";
|
echo '<h4>' . __( 'Drafts' ) . "</h4>\n<ul>";
|
||||||
|
|
||||||
$drafts = array_slice( $drafts, 0, 3 );
|
$drafts = array_slice( $drafts, 0, 3 );
|
||||||
foreach ( $drafts as $draft ) {
|
foreach ( $drafts as $draft ) {
|
||||||
$url = get_edit_post_link( $draft->ID );
|
$url = get_edit_post_link( $draft->ID );
|
||||||
|
@ -550,7 +550,7 @@ function dashboard_show_published_posts( $args ) {
|
||||||
dashboard_relative_date( get_the_time( 'U' ) ),
|
dashboard_relative_date( get_the_time( 'U' ) ),
|
||||||
get_the_time(),
|
get_the_time(),
|
||||||
get_edit_post_link(),
|
get_edit_post_link(),
|
||||||
get_the_title()
|
_draft_or_post_title()
|
||||||
);
|
);
|
||||||
$i++;
|
$i++;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue