function recentChangesLineOld( &$rc, $watched = false )
{
- global $wgTitle, $wgLang, $wgUser;
+ global $wgTitle, $wgLang, $wgUser, $wgRCSeconds;
# Extract DB fields into local scope
extract( $rc->mAttribs );
}
# Timestamp
- $s .= "; " . $wgLang->time( $rc_timestamp, true ) . " . . ";
+ $s .= "; " . $wgLang->time( $rc_timestamp, true, $wgRCSeconds ) . " . . ";
# User link (or contributions for unregistered users)
if ( 0 == $rc_user ) {
# function recentChangesLineNew( $ts, $u, $ut, $ns, $ttl, $c, $isminor, $isnew, $watched = false, $oldid = 0 , $diffid = 0 )
function recentChangesLineNew( &$baseRC, $watched = false )
{
- global $wgTitle, $wgLang, $wgUser;
+ global $wgTitle, $wgLang, $wgUser, $wgRCSeconds;
# Create a specialised object
$rc = RCCacheEntry::newFromParent( $baseRC ) ;
$clink = $this->makeKnownLinkObj( $rc->getTitle(), "" ) ;
}
- $time = $wgLang->time( $rc_timestamp, true );
+ $time = $wgLang->time( $rc_timestamp, true, $wgRCSeconds );
$rc->watched = $watched ;
$rc->link = $clink ;
$rc->timestamp = $time;
}
}
- function time( $ts, $adj = false )
+ function time( $ts, $adj = false, $seconds = false )
{
if ( $adj ) { $ts = $this->userAdjust( $ts ); }
$t = substr( $ts, 8, 2 ) . ":" . substr( $ts, 10, 2 );
+ if ( $seconds ) {
+ $t .= ":" . substr( $ts, 12, 2 );
+ }
return $this->formatNum( $t );
}