WordPress.org

Make WordPress Core

Opened 4 years ago

Closed 4 years ago

Last modified 4 years ago

#33238 closed defect (bug) (fixed)

Wrong date in Uploaded to column and missing localization

Reported by: pavelevap Owned by: ocean90
Milestone: 4.4 Priority: normal
Severity: normal Version:
Component: I18N Keywords: has-patch
Focuses: Cc:
PR Number:

Description

When media file is attached to any post (generally content), you can see in "Uploaded to" column a link to parent post and date. But this date is the same date as in "Date" column, so I think that it should be publishing date of parent post? So in column_parent() function in WP_Media_List_Table we should switch from:

<?php echo get_the_time( __( 'Y/m/d' ) ); ?><br />

to:

<?php echo get_the_time( __( 'Y/m/d' ), $parent ); ?><br />

And there is also related problem with hardcoded comma, which can be problem for some languages, because it is not possible to localize it:

echo $title;
} ?></strong>,
<?php echo get_the_time( __( 'Y/m/d' ), $parent ); ?><br />

There should be something like %1$s, %2$s with translators comment that first is post title and second post date?

Attachments (1)

33238.1.patch (598 bytes) - added by jmayhak 4 years ago.

Download all attachments as: .zip

Change History (6)

#1 @ocean90
4 years ago

  • Keywords needs-patch added
  • Milestone changed from Awaiting Review to Future Release
  • Version trunk deleted

@jmayhak
4 years ago

#2 @jmayhak
4 years ago

  • Keywords has-patch ux-feedback added; needs-patch removed

33238.1.patch Here's the change where the date is based off parent post. I also got rid of the "," and replaced it with a "<br />" like is done with the Title column to separate the media title from the file name.

#3 @pavelevap
4 years ago

Maybe it could be better to let translators choosing best format? I would prefer for example brackets for date, for some languages can be also comma good solution...

#4 @ocean90
4 years ago

  • Owner set to ocean90
  • Resolution set to fixed
  • Status changed from new to closed

In 34839:

Media List Table: Remove the date display in column_parent().

It should be the time at which the post was written, but it was never because of the missing $parent argument.

Fixes #33238.

#5 @ocean90
4 years ago

  • Keywords ux-feedback removed
  • Milestone changed from Future Release to 4.4
Note: See TracTickets for help on using tickets.