r51579 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r51578‎ | r51579 | r51580 >
Date:23:51, 7 June 2009
Author:siebrand
Status:resolved (Comments)
Tags:
Comment:
Allow splitting time and date with $4 and $5 for 'revision-info-current' and 'revision-info'
Modified paths:
  • /trunk/phase3/includes/Article.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/Article.php
@@ -3083,6 +3083,8 @@
30843084
30853085 $current = ( $oldid == $this->mLatest );
30863086 $td = $wgLang->timeanddate( $this->mTimestamp, true );
 3087+ $tddate = $wgLang->time( $this->mTimestamp, true );
 3088+ $tdtime = $wgLang->time( $this->mTimestamp, true );
30873089 $sk = $wgUser->getSkin();
30883090 $lnk = $current
30893091 ? wfMsgHtml( 'currentrevisionlink' )
@@ -3191,11 +3193,19 @@
31923194 ? 'revision-info-current'
31933195 : 'revision-info';
31943196
3195 - $r = "\n\t\t\t\t<div id=\"mw-{$infomsg}\">" . wfMsgExt( $infomsg, array( 'parseinline', 'replaceafter' ),
3196 - $td, $userlinks, $revision->getID() ) . "</div>\n" .
3197 -
3198 - "\n\t\t\t\t<div id=\"mw-revision-nav\">" . $cdel . wfMsgExt( 'revision-nav', array( 'escapenoentities', 'parsemag', 'replaceafter' ),
3199 - $prevdiff, $prevlink, $lnk, $curdiff, $nextlink, $nextdiff ) . "</div>\n\t\t\t";
 3197+ $r = "\n\t\t\t\t<div id=\"mw-{$infomsg}\">" .
 3198+ wfMsgExt(
 3199+ $infomsg,
 3200+ array( 'parseinline', 'replaceafter' ),
 3201+ $td,
 3202+ $userlinks,
 3203+ $revision->getID(),
 3204+ $tddate,
 3205+ $tdtime
 3206+ ) .
 3207+ "</div>\n" .
 3208+ "\n\t\t\t\t<div id=\"mw-revision-nav\">" . $cdel . wfMsgExt( 'revision-nav', array( 'escapenoentities', 'parsemag', 'replaceafter' ),
 3209+ $prevdiff, $prevlink, $lnk, $curdiff, $nextlink, $nextdiff ) . "</div>\n\t\t\t";
32003210 $wgOut->setSubtitle( $r );
32013211 }
32023212

Follow-up revisions

RevisionCommit summaryAuthorDate
r52175Follow-up to r51579: fix copy paste error (time->date) per CRsiebrand19:30, 19 June 2009

Comments

#Comment by Umherirrender (talk | contribs)   19:28, 19 June 2009

$wgLang->time( $this->mTimestamp, true ); is used twice ...

#Comment by Siebrand (talk | contribs)   19:31, 19 June 2009

Fixed in r52175

Status & tagging log