Page MenuHomePhabricator

Results on Special:Search should display user-preferred time
Closed, ResolvedPublic

Description

Search results on Special:Search displays time of last edit using UTC, at least on Commons where I have different user preferences, and logged-out on sv.wikipedia which otherwise uses CET.
I think this time should be displayed using user preferred time. That will make it consistent with the same time displayed at the bottom of articles and in page histories.

I think it should be easy to fix by changing line 649 of SpecialSearch.php[1] from:

$date = $lang->timeanddate( $timestamp );

to

$date = $lang->timeanddate( $timestamp, true );

[1] https://svn.wikimedia.org/viewvc/mediawiki/trunk/phase3/includes/specials/SpecialSearch.php?revision=108712&view=markup


Version: unspecified
Severity: normal

Details

Reference
bz34727

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 22 2014, 12:15 AM
bzimport set Reference to bz34727.
bzimport added a subscriber: Unknown Object (MLST).

See Bug 19992. Fixing this in the way you suggest would probably mean caching problems and won't happen.

  • This bug has been marked as a duplicate of bug 19992 ***

Maybe user time is difficult because of caching. I did not think search results were cached.

But if user time is not possible, wiki default time would be better than UTC. For example CET at Swedish Wikipedia, and EET at Finnish Wikipedia. That will make the displayed times consistent for loggedout users and users with the default time preferences.

I will try reopen this bug and change it to display wiki default time.

(In reply to comment #1)

See Bug 19992. Fixing this in the way you suggest would probably mean caching
problems and won't happen.

Search results pages aren't cached in squid like you're suggesting.

Glaisher renamed this task from Results on Special:Search should display wiki time to Results on Special:Search should display user-preferred time.Jun 8 2015, 5:19 PM
Glaisher closed this task as Resolved.
Glaisher set Security to None.
Glaisher removed a subscriber: Unknown Object (MLST).
Glaisher subscribed.

It shows user time now.