15use Wikimedia\Timestamp\TimestampFormat as TS;
29 private function formatTime( $timestamp ) {
32 return gmdate(
'Y-m-d\TH:i:s', (
int)
wfTimestamp( TS::UNIX, $timestamp ) );
50 'feedID' => $this->getSelfUrl(),
53 $this->urlUtils->expand( $this->getUrlUnescaped(),
PROTO_CURRENT ) ??
''
55 'selfUrl' => $this->getSelfUrl(),
60 print $this->templateParser->processTemplate(
'AtomHeader', $templateParams );
68 private function getSelfUrl() {
70 return htmlspecialchars(
$wgRequest->getFullRequestURL() );
84 "uniqueID" => $item->getUniqueID(),
85 "title" => $item->getTitle(),
86 "mimeType" => $this->
xmlEncode( $mimeType ),
88 $this->urlUtils->expand( $item->getUrlUnescaped(),
PROTO_CURRENT ) ??
''
91 "description" => $item->getDescription(),
92 "author" => $item->getAuthor()
94 print $this->templateParser->processTemplate(
'AtomItem', $templateParams );
const MW_VERSION
The running version of MediaWiki.
wfTimestampNow()
Convenience function; returns MediaWiki timestamp for the present time.
wfTimestamp( $outputtype=TS::UNIX, $ts=0)
Get a timestamp string in one of various formats.
A class containing constants representing the names of configuration variables.
const MimeType
Name constant for the MimeType setting, for use with Config::get()